-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathangle-clock
More file actions
23 lines (18 loc) · 720 Bytes
/
angle-clock
File metadata and controls
23 lines (18 loc) · 720 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#girilen acilar tam sayi olacagi icin cogunlukla, buna karsilik gelen dakika degeri kusuratli cikiyor. Bunu ayrica saniye-saliseye cevirmeden,
#tam degerini gostermeye calistim. orn: "time is : 13 : 12.727272727272727 "
a=int(input("Enter the angle: "))
a=a%360
for i in range(1,13):
v=(a+(i%12)*30)*2/11
print("time is : ",i+12,":",(v%60))
=============================================
#for integer solution
a=int(input("Enter the angle: "))
a=a%360
for i in range(1,13):
k=(a+(i%12)*30)*2/11
l=((i%12)*30-a)*2/11
if (k%60).is_integer():
print(i+12,":",int(k%60),",",i,":",int(k%60),sep="")
if (l%60).is_integer():
print(i+12,":",int(l%60),",",i,":",int(l%60),sep="")