Python 35.2 hashtag generator | SoloLearn: Learn to code for FREE!


Python 35.2 hashtag generator

Getting a lot of python work in today! If someone could help me figure out where my code went wrong that would be great! The SoloLearn material is great but they don’t teach how to handle input in the lessons groups often, then tell us to do all input stuff with it in their challenge problems. Tough sometimes, like this! The input is a word or string and it removes spaces and prefixes with a hashtag. How can I fix my code to do that?

1/23/2021 6:34:37 PM

Steve Barone

4 Answers

New Answer


Steve Barone Return text1 or do like this s = input() def hashtagGen(text): #your code goes here return ("#" + text.replace(" ", "")) print(hashtagGen(s))


Your function does not return text1, that's why there is no output.


ah thanks Lisa, the simple mistakes always seem to get ya! I Am AJ ! appreciate the input, i will try your method as well!


In the name of kindly generous ALLAH Hello Try this!)