0

How to print number is c++

2,4,6,8,10,14,16,18,20 till.

21st May 2018, 3:37 PM
Mahendra Kumar
Mahendra Kumar - avatar
5 Answers
+ 5
for(int i=2;i<20;i+=2){ cout<<i; } https://www.sololearn.com/learn/CPlusPlus/1616/
21st May 2018, 3:56 PM
᠌Bidex
᠌Bidex - avatar
+ 4
Mahendra Kumar i might suggest you read the c++ course from scratch
21st May 2018, 4:00 PM
᠌Bidex
᠌Bidex - avatar
0
I don't understand
21st May 2018, 3:57 PM
Mahendra Kumar
Mahendra Kumar - avatar
0
Please tell me course syllabus send
21st May 2018, 4:56 PM
Mahendra Kumar
Mahendra Kumar - avatar
0
just use for loop... use iteration expression as. (variable+=2) or (variable=variable+2) this statement will increment the variable by 2 https://code.sololearn.com/cXhO9UMdL7Jp/?ref=app
21st May 2018, 5:01 PM
Sreejith P
Sreejith P - avatar