हिंदी

Predict the output: int i, j; for (j = 1; j <= 5; j += 2) { for (k = 1; k <= j; k++) System.out.print(k); System.out.println(); } - Computer Applications

Advertisements
Advertisements

प्रश्न

Predict the output:

int i, j;
for (j = 1; j <= 5; j += 2)
{
     for (k = 1; k <= j; k++)
        System.out.print(k);
System.out.println();
}
संक्षेप में उत्तर

उत्तर

1
123
12345 

shaalaa.com
  क्या इस प्रश्न या उत्तर में कोई त्रुटि है?
अध्याय 1.1: Nested Loop - Review Insight [पृष्ठ १४३]

APPEARS IN

अविचल Computer Applications [English] Class 10 ICSE
अध्याय 1.1 Nested Loop
Review Insight | Q 4. | पृष्ठ १४३
Share
Notifications

Englishहिंदीमराठी


      Forgot password?
Use app×