Write a C program to print 1 2 3 ... 100 without using
loops?
Answer Posted / harsha
#include<stdio.h>
int i=0;
void main()
{
if(i==0)
clrscr();
if(i<100) {
printf("%d \t",++i);
main(); }
else {
getch();
exit(0); }
}
| Is This Answer Correct ? | 2 Yes | 1 No |
Post New Answer View All Answers
Why C language is a procedural language?
What is data structure in c and its types?
Write a program to print "hello world" without using a semicolon?
what do you mean by inline function in C?
What does 1f stand for?
write a program in C that prompts the user for today's date,tomorrow's date and display the results.Use structures for today's date,tomorrow's date and an array to hold the days for each month of the year.
What is pointer & why it is used?
How do you do dynamic memory allocation in C applications?
What are the types of i/o functions?
Explain what is a 'null pointer assignment' error? Explain what are bus errors, memory faults, and core dumps?
How do we open a binary file in Read/Write mode in C?
How does struct work in c?
An application package has been provided to you without any documents for the following application. The application needs to be tested. How will you proceed?
write a c program to print the next of a particular no without using the arithmetic operator or looping statements?
What are 3 types of structures?