kann mir jemand bei diesem programm helfen?

Riccoestevez

Grünschnabel
kann mir jemand ein wenig weiterhelfen, und mir ein tipp geben wie ich dieses programm zum starten kriege

ich bin echt ratlos...bin halt gerade am beginn

danke
!?


#include <stdio.h>
#include <math.h>
#include <conio.h>
void main(){
//------------------- VARIABLE declaration section -----------------
// NO additional variables below, PLEASE
short i=0, j=0;
char ch, step_ch;
short int short_i, step_16;
long int long_i, step_32;
double d=1e-10;
//------------- end of VARIABLE declaration section ----------------
printf("Enter step sizes for CHAR, INT16 and INT32 (use 2, 16, 65536) : \n");
scanf("%c", step_ch);
scanf("%d", step_16);
scanf("%d", step_32);
printf("Your step sizes are %d for CHAR, %d for INT16 and %d for INT32\n",
step_ch, step_16, step_32);
for (ch=120; ch<131; ch+=step_ch)
printf("The square of CH8 %hd is %hd\n", ch, ch*ch);
for (short_i=4;short_i<300; short_i+=step_16)
printf("The square of INT16 %d is %d\n", short_i, short_i*short_i);
for (long_i=16384;long_i<pow(2,20); long_i+=65536)
printf("The square of INT32 %d is %d\n", long_i, long_i*long_i);
printf("The square of DOUBLE %d is %d\n", d, d*d);
}
 
Zurück