788 views

1 Answer

2 2 votes

It will print 1,2,3,4,5,7

It is a preincrement of i . So every time it  first increment and then assign the value and print

So, upto 5 it will print

Then it will go to ' if ' part of program 

There i value becomes 7 , breaks the loop and exit

• edited by
Position:
Show:

Related questions

0 0 votes
3 3 answers
1.1k
1.1k views
go_editor asked Jun 8, 2016
1,093 views
Someone claims that Kruskal's algorithm for finding minimum spanning tree can return different spanning trees for the same input graph $G$. Do you agree with the claim? I...
1 1 vote
4 4 answers
1.2k
1.2k views
go_editor asked Jun 8, 2016
1,227 views
A proper vertex colouring of a graph $G$ is a colouring of the vertices in $G$ in such a way that two vertices get different colours if they are adjacent. The minimum num...
0 0 votes
2 2 answers
809
809 views
go_editor asked Jun 8, 2016
809 views
Which of the following statement(s) is(are) true?If $n$ is odd prime number then $2^{n-1} \text{ mod } n =1$If $2^{n-1} \text{ mod } n =1$ for a number $n$ then $n$ is pr...
2 2 votes
1 answers 1 answer
560
560 views
go_editor asked Jun 8, 2016
560 views
Write the truth table for the connective: "If A then B"