Subscribe to:
Post Comments
(
Atom
)
(adsbygoogle = window.adsbygoogle || []).push({ google_ad_client: "ca-pub-2960223314593660", enable_page_level_ads: true });
Write a C program to print all natural numbers from 1 to n using for loop.
ReplyDeleteCode of given problem:
int main()
{
int i=1,n;
printf("Enter the number to print all natural number till that entered number\t");
scanf("%d",&n);
for(i=1;i<=n;i++)
{
printf("%d\t",i);
}
return 0;
}
Very informative blog!
Please take some time to visit my blog @
for loop program examples
Thanks!
good boy malan
ReplyDelete