10 lines
276 B
C
10 lines
276 B
C
main() /* Example 2.1 */
|
|
{ /* figure distance traveled */
|
|
int mph,time;
|
|
printf("Enter your speed in miles per hour: ");
|
|
scanf("%d",&mph);
|
|
printf("Enter the number of hours: ");
|
|
scanf("%d",&time);
|
|
printf("Miles traveled = %d \n", mph * time);
|
|
}
|