1.
If age < 10:
Print (“Children”)
If age > 60:
print (‘senior citizens’)
If 10< age> 60:
print (‘normal citizen’)
2. If male and sr. citizen :
Print (“ 70% of fare is applicable”)
Print(fare*=0.7)
If female and sr. citizen :
Print (“50% of fare is applicable.”)
Print(fare*=0.5)
If female and normal citizen :
Print (“ 70% of fare is applicable”)
Print(fare*=0.7)
If male and normal citizen
Print (“ 100% of fare is applicable”)
3. If num > 0:
If num/5==0:
Print(“condition satisfied”)
Else:
Print(“condition is not satisfied”)
Conditional statements
1. A. Print(list1)
B. for i in range(0,n)
Print(i)
C. n = input (“”)
. for i in range(0,n)
Print(i)
2. list1= [0,1,2,3....9]
list2= ['zero','one','two',.... ,'nine']
list3=[Link]()
list3=[Link]()
3. list1 [3,4,5,6,7,8]
for i in list1:
if i /2 ==0:
i+=10
else:
i*=5
4. def function1 ( name , message = “how are you” ):
print (f ”hello {name}, {message}”)
function1(chaitanya,message)