Write a program that prints a table converting miles to/from kilometers, exactly as shown in the sample run. Your code must demonstrate the use of a while and a for loop (have some of the code done using a while loop and the some other using the for loop)

Note that: One Mile = 1.6 Kilometer.

Sample run 1: User's entry is in blod

Welcome to the distance converter program (miles<->kms)
***********************************************************************
Enter how many conversions would you like to print ( up to 99) : 15
=====================================
| 15 mlies = 24.00 km | 1 km = 0.63 miles |
| 14 mlies = 22.40 km | 2 km = 1.25 miles |
| 13 mlies = 20.80 km | 3 km = 1.88 miles |
| 12 mlies = 19.20 km | 4 km = 2.50 miles |
| 11 mlies = 17.60 km | 5 km = 3.13 mile s |
| 10 mlies = 16.00 km | 6 km = 3.75 miles |
| 9 mlies = 14.40 km | 7 km = 4.38 mile s |
| 8 mlies = 12.80 km | 8 km = 5.00 mile s |
| 7 mlies = 11.20 km | 9 km = 5.63 miles |
| 6 mlies = 9.60 km | 10 km = 6.25 miles |
| 5 mlies = 8.00 km | 11 km = 6.88 miles |
| 4 mlies = 6.40 km | 12 km = 7.50 miles |
| 3 mlies = 4.80 km | 13 km = 8.13 miles |
| 2 mlies = 3.20 km | 14 km = 8.75 miles |
| 1 mlies = 1.60 km | 15 km = 9.38 miles |
=====================================
Thank you for choosing our conversion program!

Sample run 2: User's entry is in blod

Welcome to the distance converter program (miles<->kms)
***********************************************************************
Enter how many conversions would you like to print ( up to 99) :150
Number out of range (1 to 99 lines)! Try again :100
Number out of range (1 to 99 lines)! Try again :0
Number out of range (1 to 99 lines)! Try again :3
====================================
| 3 mlies = 4.80 km | 1 km = 0.63 miles |
| 2 mlies = 3.20 km | 2 km = 1.25 miles |
| 1 mlies = 1.60 km | 3 km = 1.88 miles |
====================================
Thank you for choosing our conversion program!

Before you start your code, try the following code segment:

int myInteger = 15;
float myFloat = 84.2561;
printf ("abc%dxyz\n", myInteger);
printf ("abc%10dxyz\n", myInteger);
printf ("abc%-10dxyz\n\n\n", myInteger);
printf ("abc%fxyz\n", myFloat);
printf ("abc%.2fxyz\n", myFloat);
printf ("abc%10.2fxyz\n", myFloat);
printf ("abc%-10.2fxyz\n", myFloat);
Academic Honesty!
It is not our intention to break the school's academic policy. Posted solutions are meant to be used as a reference and should not be submitted as is. We are not held liable for any misuse of the solutions. Please see the frequently asked questions page for further questions and inquiries.
Kindly complete the form. Please provide a valid email address and we will get back to you within 24 hours. Payment is through PayPal, Buy me a Coffee or Cryptocurrency. We are a nonprofit organization however we need funds to keep this organization operating and to be able to complete our research and development projects.