|
各位大虾,帮我看看,错哪了。好困惑。。 :mad: :mad: :mad:
#include "Stdio.h"
#include "Conio.h"
#define pi=3.14159
int main(void)
{
double Radius,Flaeche,Unfang;
char frage;
do {
printf("A = Flaeche\n");
printf("U = Unfang\n");
printf("Q = Beenden\n");
printf("bitte Wahlen ");
switch(frage) {
case 'A':
printf("\nGeben Radius = ");
scanf("%lf", &Radius);
Flaeche = Radius*Radius*pi;
printf("Flaeche = %lf\n", Flaeche);
break;
case 'U':
printf("\nGeben Radius = ");
scanf("%lf", &Radius);
Unfang = 2*Radius*pi;
printf("Unfang = %lf\n", Unfang);
break;
case 'Q':
printf("beenden\n");
break;
default:
printf("falsch\n");
}
printf("\n\n");
getch();
} while( frage!= 'Q');
getch();
return 0;
} |
|