Write a Pseudo Code to find the angle between two hands of a
clock for a given time.
Answer Posted / spacious mamun
#include<stdio.h>
int main()
{
int angle,hour,minute;
printf("Enter the hour: ");
scanf("%d", &hour);
printf("Enter the minute: ");
scanf("%d", &minute);
if(hour < 12) // In case of 24 hour clock
hour=hour+12;//to make the hour in 24 hour format;
{
(int)angle = hour * 30 - minute * 6;
if(angle > 180)
angle = 360 - angle;
printf("The angle between the two handle is: ");
printf("%d\n", angle);
}
return 0;
}
| Is This Answer Correct ? | 12 Yes | 11 No |
Post New Answer View All Answers
What is the use of sas software? Is sas and sap are different?
Bonjour, svp je veut voir comment envoyer un mail en java et comment changer le droit d'accé d'un fichier en java: de lecture en lecture/écriture et merci d'avance ;)
What are the Short cut Keys of Tally ERP?
in IT trend mantis meant what? how to know mantis in IT trends? detail description about mantis?
what is web service in java? have u use before.
< No Frames > tag is used for
Is anyone has done the ASP.NET MVC4 workshop course(2 days) from Peers Technologies. Let me know. I need to talk before joining ASP.NET MVC4 training at peers, Hyderabad.
I want sample papers for NIC Examination. Plz send them to my mail Id das.neelam@gmail.com . Plz send it today, tomorrow i've the exam.
pleasew define carrier scope in abap (sap).
3. What is the difference between testing and Quality Assurance?
What is the use of Differ interface check box in Ship confirm?
Tips for blog integration by www.esteemwebsolutions.com. Can Any body suggest me to how to make wonderful questions on web integration..
public static void main(String args[]) describe it
what is integration testing in real time applications?
hi This is radhika.Can anyone help me to know the question papers of NATIONAL INFORMATICS CENTRE for the post of scientific officer/engineer? if anyone know plz tell me question paper pattern