- 2

Need some help in py

I have assigned x = "hero" now I want to write a script by which when the user inputs the word x the output should be hero

5th Jul 2017, 7:33 AM
JULIAN ANTHONY
JULIAN ANTHONY - avatar
5 odpowiedzi
+ 5
# Did you mean: x = 'hero' inp = input('Enter a word: ') if inp == x: print(x) else: print('Wrong answer...') # ?
5th Jul 2017, 10:21 AM
visph
visph - avatar
+ 3
Ok... but now you've understanded the principle, don't you? ;P
5th Jul 2017, 10:31 AM
visph
visph - avatar
0
can u write the whole script?
5th Jul 2017, 9:22 AM
JULIAN ANTHONY
JULIAN ANTHONY - avatar
0
thanks for the answer but this is what I really meant : https://code.sololearn.com/cTNGg6aD2xr3/?ref=app
5th Jul 2017, 10:29 AM
JULIAN ANTHONY
JULIAN ANTHONY - avatar
0
yes thanks for the help.
5th Jul 2017, 12:32 PM
JULIAN ANTHONY
JULIAN ANTHONY - avatar