-
Which of the following is the correct output for the program given below?
#include <studio.h>
int main ( )
{
char j = 1;
while (j <= 255)
{
printf("%d",j );
j = j + 1;
}
printf ( "\n");
return 0;
}
-
- 1 2 3 ..... 127
- 1 2 3 ... 255
- 1 2 3 ..... 254 255 0 1 2 3 .. 254 255 ... infinite times
- 1 2 3 .... 127 128 0 1 2 3 .. 127 128 .. infinite times
- 1 2 3 .. 127 -128 -127 -126 .. -2 -1 0 1 2 .. 127 -128 -127 .. infinite times
Correct Option: E
1 2 3 .. 127 -128 -127 -126 .. -2 -1 0 1 2 .. 127 -128 -127 .. infinite times