Input
1)h 2)m 3)s
output
1)Sec
Method
1.start
2.Read h,m & s
3.write h,m & s
4. H=h*60*60;
M=m*60;
S=s;
Sec=H+M+S;
5.Write Sec;
Example:
Input
h=1
m=30
s=10
Output
Sec=5410
#python program
h=int(input("Enter Hour:")
m=int(input("Enter Minutes:")
s=int(input("Enter Seconds:")
H=h*60*60
M=m*60
S=s
Sec=H+M+S
print("In Seconds=",Sec)
No comments:
Post a Comment