Last active
August 29, 2015 14:11
-
-
Save Code-Hex/623b2d1ebc74c2695aa4 to your computer and use it in GitHub Desktop.
4-3
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(){ | |
float vertically, horizontally; | |
float inch = 2.54; | |
float ans; | |
printf("まずは横の入力\n"); | |
scanf("%f",&vertically); | |
printf("よしよし、次は縦の入力\n"); | |
scanf("%f",&horizontally); | |
vertically *= inch; | |
horizontally *= inch; | |
ans = vertically * horizontally; | |
printf("面積は%05f cm^2だよー\n", ans); | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
単位はしっかり書こう!
(俺も忘れてたけどw)