Welcome to the Treehouse Community
Looking to learn something new?
Please Help! I am stuck!
I have been attempting the squared task in Stage 5 and cannot seem to get the code correct. Any hint at what I may be doing incorrectly would be much appreciated.
# EXAMPLES # squared(5) would return 25 # squared("2") would return 4 # squared("tim") would return "timtimtim" def squared(square): square=input("What shall we square? ") try: convert=int(square) except ValueError: return(square*len(square)) return(convert*convert)
I don't think the challenge is looking to take an input, so remove
square=input("What shall we square? ")
It worked when I removed that line