C/C++の宿題を片付けます 107代目
■ このスレッドは過去ログ倉庫に格納されています
0266デフォルトの名無しさん
2008/05/21(水) 00:16:49#include<stdio.h>
#include<math.h>
#define PI 3.14159
int main(void){
int alpha, degree;
double theta;
printf("終了する角度を入力してください ");
scanf("%d", &alpha);
for(degree=0;degree<=alpha;degree+=5){
theta=PI*degree/180;
printf(" 角度θ= %d°sinθ= %.5f cosθ= %.5f\n", degree, sin(theta), cos(theta));
}
return 0;
}
■ このスレッドは過去ログ倉庫に格納されています