Home > other >  Python 3 study notes, in the basic learning python suddenly think of properties are obtained by the
Python 3 study notes, in the basic learning python suddenly think of properties are obtained by the

Time:09-21

X=int (input (" how old you are?" ))
12 v=(x %)
If v==0:
Print (" (dragon) "is your animal sign: morning. The format (v))
Elif v==1:
Print (" your animal sign is: the third (snake) ". The format (v))
Elif v==2:
Print (" your animal sign is: lunch (horse) ". The format (v))
Elif v==3:
Print (" is your animal sign: no (sheep) ". The format (v))
Elif v==4:
Print (" your animal sign is: "(monkey)". The format (v))
Elif v==5:
Print (" your animal sign is: unitary (chicken) ". The format (v))
Elif v==6:
Print (" is your animal sign, xu-gou (dog) ". The format (v))
Elif v==7:
Print (" your animal sign is: hai (pig) ". The format (v))
Elif v==8:
Print (" your animal sign is a: son (rat) ". The format (v))
Elif v==9:
Print (" your animal sign is: ugly (cow) ". The format (v))
Elif v==10:
Print (" your animal sign is: Yin (tiger) ". The format (v))
Elif v==11:
Print (" your animal sign is: frame (rabbit) ". The format (v))

CodePudding user response:

 
X=int (input (" your age: "))
Shengxiao=[' pig ', 'dog', 'chicken', 'monkey', 'sheep', 'ma', 'snake', 'dragon' and 'rabbit', 'tiger', 'cow', 'the rat]
Print (shengxiao)
V=x % 12-1
Print (f 'is your animal sign: {shengxiao [v]}')
  • Related