How many times will I be printed? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

How many times will I be printed?

#include<stdio.h> int i; for (i=1;i <=5;printf ("%d",i)); i++;

14th Feb 2020, 4:15 PM
Learner Laxmi
3 Answers
+ 2
You can use the tags to include language specification instead of asking "anyone please explain". Tags are used by search engine to find threads under similar topics by matching the search terms against thread tags. Use of irrelevant words in tags will lessen the searchability of the thread.
14th Feb 2020, 4:32 PM
Ipang
+ 2
I was bit confused previous regarding the tags but now I am clear
14th Feb 2020, 4:34 PM
Learner Laxmi
+ 1
You can edit the tags now also.. Infinite loop with ; at end. But if you remove ; then, 2 to 6 printed.
14th Feb 2020, 7:42 PM
Jayakrishna 🇮🇳