Want more features on Pastebin? Sign Up, it's FREE!
Guest

Untitled

By: a guest on Oct 3rd, 2011  |  syntax: C  |  size: 0.47 KB  |  views: 55  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. #include <studio.h>
  2. #include <math.h>
  3.  
  4. int
  5. main(void)
  6. {
  7.         int beg_reading, end_reading, traveled;
  8.         printf("MILEAGE REIMBURSEMENT CALCULATOR");
  9.         printf("Enter beginning odometer reading=> ", beg_reading);
  10.         scanf("%d", &beg_reading);
  11.         printf("Enter ending odometer reading => ", end_reading);
  12.         scanf("%d", &end_reading);
  13.         traveled = end_reading - beg_reading;
  14.         printf("You traveled %d miles.", traveled);
  15.         printf("Your reimbursement is %f, traveled * .35);
  16.         return(0);
  17. }
  18.  
  19.  
clone this paste RAW Paste Data