Advertisement
ThetOo

Mile to metre,yard,centimetre,foot,inch

Feb 23rd, 2020
119
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.51 KB | None | 0 0
  1. #include <stdio.h>
  2.  
  3. int main() {
  4.    
  5.     int mile=0;
  6.     int total=0;
  7.     int yard=0;
  8.     int centi=0;
  9.     int foot=0;
  10.     int inch=0;
  11.     printf("Please Enter Your Mile:");
  12.     scanf("%d",&mile);
  13.     total=1609.34*mile;
  14.     yard=1760*mile;
  15.     centi=160934*mile;
  16.     foot=5280*mile;
  17.     inch=63360*mile;
  18.    
  19.     printf("This is Your Metre:%d\n",total);
  20.     printf("This is Your Yard:%d\n",yard);
  21.     printf("This is Your Centimeter:%d\n",centi);
  22.     printf("This is Your Foot:%d\n",foot);
  23.     printf("This is Your Inch:%d",inch);
  24.    
  25.    
  26.    
  27.    
  28.    
  29.     return 0;
  30.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement