Important MCQ

Output? for (int i = 1; i <= 3; i++) { for (int j = 1; j <= i; j++) cout << "*"; cout << endl; }

Q.Output? for (int i = 1; i <= 3; i++) { for (int j = 1; j <= i; j++) cout << "*"; cout << endl; }

A) 3 rows of ***
B) *. **, *** (each on a new line)
C) ***, **, *
D) 9 stars in one line
Correct Answer:
Option B