Skip to content

Commit 7d5f6b9

Browse files
committed
Updated Javadocs for for loop
1 parent 39cdfa1 commit 7d5f6b9

1 file changed

Lines changed: 7 additions & 6 deletions

File tree

src/test/java/com/rhcloud/test/forloop/ForLoop.java

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,12 +10,13 @@
1010
* These tests show that the post increment OR pre increment operators do not make a difference in for loops when added in the third statement.
1111
* This is because the increment part (third statement in for loop -- after second semicolon) is run after the loop is run first.
1212
*
13-
* 1. So First Initialize {@code i}
14-
* 2. Check if Condition matches {@code (i < 10)}
15-
* 3. Run For loop body
16-
* 4. Increment
17-
* 5. Run from 2 to 4 till 2 return false.
18-
*
13+
* <ol>
14+
* <li>So First Initialize {@code int i}</li>
15+
* <li>Check Condition {@code if (i < 10)} then proceed </li>
16+
* <li>Run For loop body </li>
17+
* <li>Increment {@code i++ OR ++i} no difference as value is not currently assigned.</li>
18+
* <li>Run from 2 to 4 till 2 returns {@code false}.</li>
19+
* </ol>
1920
* @author Guruprasad Kulkarni <guru@linux.com>
2021
*/
2122
public class ForLoop {

0 commit comments

Comments
 (0)