Dim h,m
h=cint(inputbox("Enter the hour:"))
m=cint(inputbox("Enter the minutes:"))
If 5.5*m>30*h Then
msgbox 5.5*m-30*h
else
msgbox 30*h-5.5*m
End If
just copy paste the code in QTP or UFT then you will get the angle between the hands in the clock
note: here the reference takes from clock wise and from 0 angle starts from 12 digit.
h=cint(inputbox("Enter the hour:"))
m=cint(inputbox("Enter the minutes:"))
If 5.5*m>30*h Then
msgbox 5.5*m-30*h
else
msgbox 30*h-5.5*m
End If
just copy paste the code in QTP or UFT then you will get the angle between the hands in the clock
note: here the reference takes from clock wise and from 0 angle starts from 12 digit.
No comments:
Post a Comment