Having output issue during creating a Birthday Person name. Help me out.. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

Having output issue during creating a Birthday Person name. Help me out..

BirthDate = int(input()) if BirthDate = 16 print("its sohams BirthDay") elif: BrithDate = 4 print("its mayas BirthDay") Code is this

24th May 2021, 9:59 AM
Soham Dengale
6 Answers
+ 3
Soham Dengale , here is the code after some clean up: BirthDate = int(input()) if BirthDate == 16: # comparison needs double equal == print("its sohams BirthDay") # line needs to be indented elif BirthDate == 4: # comparison needs double equal == print("its mayas BirthDay") # line needs to be indented i have seen in your profile, that you already have started with a python tutorial. may be it is helpful to repeat some parts of this totorial, to get more familiar with it. happy coding and good success!
24th May 2021, 1:15 PM
Lothar
Lothar - avatar
+ 4
Soham Dengale , it is better to post it in the q&a section. doing so, you may get multiple answers. this will gives you a more broad view on things. happy coding!
24th May 2021, 3:07 PM
Lothar
Lothar - avatar
+ 3
You have problems with the very basics of Python. Please take your time and do some lessons. Especially there are missing - Indents are part of the language they have to be applied eg. after if, elif. - if <expressoin> : - elif <expression>: Please ... the first 4 lessons of Python basics take 1 or 2 hours. You should do/repeat them. At least the 4th one.
24th May 2021, 10:30 AM
Oma Falk
Oma Falk - avatar
+ 1
Thanks man
24th May 2021, 2:19 PM
Soham Dengale
+ 1
Can i message you if I need help lothar
24th May 2021, 2:29 PM
Soham Dengale
0
Not understood
24th May 2021, 10:47 AM
Soham Dengale