Question: 2. Translate to C# the following Java code: 9 10 1 package lessons; 2 3 import java.util.Scanner; 4 S public class Reportsun3 6 public static
2. Translate to C# the following Java code: 9 10 1 package lessons; 2 3 import java.util.Scanner; 4 S public class Reportsun3 6 public static void main(String args) { 7 Scanner se - new Scanner(System.in); 8 // Prompt the user to enter the first integer System.out.println("Enter the value for 'o' and press Enter: "); 11 int . sc.nextInt(); 12 1/ Prompt the user to enter the second integer 13 System.out.println("Enter the value for 'b' and press Enter: "); 14 int b. sc.nextInt(); 15 16 Iclose the Scanner. It's a good practice to release the resource that was acquired 17 sc.close(); 19 1/ Display the result System.out.printf("Provided Integers: 34d and X4d, the total is $5d ", #, b, (a + b)); 21 > 22 ) 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
