Created
July 17, 2019 16:37
-
-
Save sachinsaxena25/8b222f0ca80330c5c01fd981ebbdc629 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include<stdio.h> | |
int main (void) | |
{ | |
float kilometre = 0.0f; | |
printf("please enter the value of kilometre:\n"); | |
scanf("%f", &kilometre); | |
float metre = 0.0f; | |
float feet = 0.0f; | |
float centimetre = 0.0f; | |
metre = kilometre * 1000.0f; | |
feet = metre / 3.0f; | |
centimetre = metre * 100.0f; | |
printf("metre:%.2f\n", metre); | |
printf("feet:%.2f\n", feet); | |
printf("centimetre:%.2f\n", centimetre); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment