Error in startswith function

#separating the posts beginning with Ask HN and show HN\

ask_posts = []
show_posts = []
other_posts = []
for row in hn:
    title =  row[1]
    title = title.lower
    if title.startswith('ask hn'):
        ask_posts.append(title)
    elif title.startswith('show hn'):
        show_posts.append(title)
    else:
        other_posts.append(title)
        
print(len(ask_posts))
print(len(show_posts))
print(len(other_posts))

the above giving the error
can you please help ?

Thanks
Rajas

Which exercise is that? And what is the error?

When posting your code put it between two sets of ```.

1 Like

issue resolved its a project exercise on hacker news