Write a C++ program without using any loop (if, for, while
etc) to print numbers from 1 to 100 and 100 to 1;

Answer Posted / pur

main()
{
int i =100;

start:
if( i == 0)
goto end;
printf(" %d ",i)
i--;
goto start;

end:
printf(" end of the program");
}

Is This Answer Correct ?    20 Yes 47 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are preprocessor directives?

666


Where we use clrscr in c?

694


Are enumerations really portable?

590


Is file a keyword in c?

496


Describe the header file and its usage in c programming?

616






What is the difference between malloc() and calloc() function in c language?

594


What is the explanation for prototype function in c?

563


What is the use of sizeof?

547


4. main() { int c=- -2; printf("c=%d",c); }

1364


What is call by value in c?

552


How can you access memory located at a certain address?

663


What’s a signal? Explain what do I use signals for?

601


Explain the difference between #include "..." And #include <...> In c?

621


Explain how can type-insensitive macros be created?

565


Is c high or low level?

573