Question: Examine the lava code provided in the following the tasks. Create a separate Console application for Class Library i specified for each task and rewriteava



Examine the lava code provided in the following the tasks. Create a separate Console application for Class Library i specified for each task and rewriteava code into C#following the logic of the examples. Use as many specific features as possible. Submit your work to B8, so all your source code and output can be seen in uw do your work either in Vie tudio arin Veludio code four choice! 1. Translate to the following Java code: Provide your source code and out in the form Berminated Repertum Apple Provided Integerat 2 and , the total is Provided Integers and the total is Provided Integer 1000 and 2000. the tal is Provided Integer 200 and 103, the total is 2. Translate to the following Jawa code: escom ago Provide your source code and put in the form terminated ReportSum plave Application Program File Enter the value for and press Enter Enter the value for be and press Enter: Provided Integers: s, the totalt terminated Reportiva Application Program Provided Integers! 2 and , the total is Provided Integers and the total is Provided Integers: 1000 and 2000, the total la Provided Integers 300 and 101. the total es20 K 3. Translate to C# the following code, move both methods into C# Class library App and call them from Console app. Library code provided 10 package uniti; import java.util.Scanner: public class Library public static void main(String args[]) { Scanners new Scanner(System.in); // Prompt the user to enter the number of Integer's System.out.println("What number of integers you will provide : "); int nunc.nextInt(); // Prompt the user to enter the first Integer Systen.out.println("Enter the value for and press Enter: "); int . sc.nextInt(); // Prompt the user to enter the second Integer System.out.println("Enter the value for 'b' and press Enter: "); int. Sc.nextInt(); if (nur - )) 1 Prompt the user to enter the third Integer System.out.println("Enter the value for 'e' and press Entert ) Int . sc.nextInt(); // Display the result System.out.printf("Provided Integers: x4d and Bad and Xed, the total is d ", a, b, sumo, be else // Display the result System.out.printf("Provided Integersi ad and Nad, the total is sd ", b, sum, b) > public static int som int nun, int num2)(1/2 parameters return nul + num2; public static int sun(int nunt, int nun, int nur>>[//3 parameters return nul nus2 num; 34 35 30 Submission: Submit both your source code and the output (both fully visible). Examine the Java code provided in the following three tasks. Create a separate Console application (or Class Library if specified) for each task and re-write Java code into C# following the logic of the examples. Use as many C# specific features as possible. Submit your work to BB, so all your source code and output can be seen in full. You can do your work either in Visual studio or in Visual studio code (your choice) 1. Translate to C# the following Java code: public class Reportsum 48 public static void main(String args[]) { //assume we have 2 numbers a and b,a - 2, b. 5 int a = 2; int b = 5; 8 System.out.println("Provided Integers: " +" and " + b + ", the total is " + (a+b)); 10 //assume we have 2 numbers a and b, a -4,5 - 4 a = 4; 12 b-4; 13 System.out.println("Provided Integers: " + + " and " + b + ", the total is + (a+b)); us // assume we have 2 numbers a and b, 1000, b - 2000 16 - 1000; 17 b-2000; 18 System.out.println("Provided Integers: " + = +" and " + b + ", the total is " + (a+b)); 19 20 1/assume we have 2 numbers and b, 100, b - 101 21 = 100; 22 b-1013 23 systen.out.println("Provided Integers: " + a + + b + ", the total is (a+b)); 24 25 ) Provide your source code and output in the form
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
