According to the given question, sales is a two-dimensional array and contains 10 rows and 7 columns wherein each component is of type integer and the variables sum and j are also of integer type.
<u>Explanation:</u>
In order to find the sum of the elements of the fifth row of sales, the correct piece of code should be:
sum=0;
for(j=0;j<7;j++)
sum=sum+sales[4][j];
The indexing in an array always starts from zero, therefore, to calculate the sum of the fifth row, the user has to write 4 in the index to point to the fifth row.
To support a position
It’s the only answer that makes sense so you’ll have to figure out the rest but to support a position is definitely correct
Log in to your account.
Visit your profile settings.
In the Privacy section, click the “Delete Account” button.
Answer:
Option (ii) is the correct option to the following code.
Explanation:
In the following code of the Java Programming Language, there is two print function after the set function then, we firstly set the value of x and print it through print function which is already declared then, we set the value of y through set function then, print the value of y through print function. So, that's why the following option is correct.