24-10-2010, 10:04 PM
|
#11
|
تاريخ التسجيل: Jul 2010
التخصص: ComPuteR ScIeNce ...
نوع الدراسة: إنتظام
المستوى: الخامس
الجنس: أنثى
المشاركات: 227
|
رد: mr.Ahmad .. pleas
هذا هو الكود استاذي :)
#include <stdio.h>
#include <conio.h>
#include <math.h>
void main ()
{
int h1,m1,h2,m2,h3,m3,th,tm,x;
printf("Enter the starting time\n");
scanf("%d, %d" ,&h1,&m1);
printf("Enter the flihgting time\n");
scanf("%d, %d\n" ,&h2,&m2);
tm=m1+m2;
x=tm/60;
m3=tm%60;
th=h1=h2=x,
h3=th%12;
if(h3<=12)
printf("Arrive's time is %d:%d a.m.", h3,m3);
else
printf("Arrive's time is %d:%d p.m.", h3,m3);
getch ();
}
|
|
سُبْحَـآنَ الله وبِحَمدِه سُبْحَـآن الله الْعَظِيِـم ..|~
|
|
|
|