Answer:
- using System;
- public class Program
- {
- public static void Main()
- {
- Console.WriteLine("Enter number of students: ");
- int num = Convert.ToInt32(Console.ReadLine());
- string [] firstName = new string[num];
- string [] lastName = new string[num];
-
- for(int i=0 ; i < num; i++){
- Console.WriteLine("Enter first name: ");
- firstName[i] = Console.ReadLine();
-
- Console.WriteLine("Enter last name: ");
- lastName[i] = Console.ReadLine();
- }
-
- for(int j=0; j < num; j++){
- Console.WriteLine(lastName[j] + "," + firstName[j]);
- }
- }
- }
Explanation:
Firstly, prompt user to enter number of student to be stored (Line 6- 7). Next, create two array, firstName and lastName with num size (Line 8-9).
Create a for-loop to repeat for num times and prompt user to enter first name and last name and then store them in the firstName and lastName array, respectively (Line 11 - 17).
Create another for loop to traverse through the lastName and firstName array and display the last name and first name by following the format given in the question (Line 19 - 21).
Answer:
a) zero b) zero
Explanation:
Newton's first law tells us that a body remains at rest or in uniform rectilinear motion, if a net force is not applied on it, that is, if there are no applied forces or If the sum of forces acting is zero. In this case there is a body that moves with uniform rectilinear motion which implies that there is no net force.
Answer:
Explanation:
1. With the operands R0, R1, the program would compute AND operation and ADD operation .
2. The operands could truly be signed 2's complement encoded (i.e Yes) .
3. The overflow truly occurs when two numbers that are unsigned were added and the result is larger than the capacity of the register, in that situation, overflow would occur and it could corrupt the data.
When the result of an operation is smaller in magnitude than the smallest value represented by the data type, then arithmetic underflow will occur.
Answer:The simplify command is used to apply simplification rules to an expression. The simplify routine searches the expression for function calls, square roots, radicals, and powers and invokes the appropriate simplification procedures. For detailed information on the simplify command, see simplify/details.
Explanation: