MCQOPTIONS
Saved Bookmarks
| 1. |
Which of the code should be added to get the following output? * * * * * * * * * * * * * * * static void Main(string[] args) { int i,j; /* Add code here */ } |
| A. | For (i = 0; i <= 4; i++) { for(j = 4; j <= i; j ) console.WriteLine( * ); console.WriteLine( );} |
| B. | For ( i = 0; i <= 4; i++ ) |
| C. | For (i = 0;i <= 4; i++) { for (j = i; j <= 4; j++) console.WriteLine( * ); console.WriteLine( ); } |
| D. | For ( i = 0;i <= 4; i++) { for (j = 0;j <= i; j++) console.WriteLine( * ); console.WriteLine( ); } |
| Answer» A. For (i = 0; i <= 4; i++) { for(j = 4; j <= i; j ) console.WriteLine( * ); console.WriteLine( );} | |