Newbi problem with Pig Latin Translator


#1

Please help ! problem with code :

print 'Welcome to the Pig Latin Translator!'

original =raw_input("Enter a word")

original =raw_input

if len(original) > 0 and original.isalpha() :

print original

else:
print "empty"


https://www.codecademy.com/en/courses/python-beginner-2W5v7/0/3?curriculum_id=4f89dab3d788890003000096#

Welcome to the Pig Latin Translator!
Enter a word Konrad
Traceback (most recent call last):
File "python", line 8, in
TypeError: object of type 'builtin_function_or_method' has no len()


#2

remove this line:

original =raw_input

this line:

original =raw_input("Enter a word")

is all you need, it has raw_input which is stored in original


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.