Debug the code provided in the starter file so it does the following:

creates an int with the maximum possible value

increases this int by 1

prints the result

creates an int with the minimum possible value

decreases this int by 1

prints the result

----------------------------------

Code:

public class U2_L7_Activity_One

{

public static void main(String[] args)

{

long a = Long. MAX_VALUE();

a + 1;

System. Out. Println(a);

long b = Long. MIN;

b - 1;

System. Out. Println('b');

}

}



Answer :

Finding and correcting code flaws is part of debugging. The following are the code errors: group name, Statements in print, declare variables, input declarations.

Debugging is the process of identifying and fixing flaws in computer programs, software, or systems. Bugs are errors or issues that prohibit proper operation.

Debugging techniques include memory dumps, profiling, control flow analysis, unit testing, integration testing, log file analysis, interactive debugging, and monitoring at the application or system level.

The program's class name is U3 L5 Activity Two.

Spaces are not permitted in class names; an underscore should be used instead.

Therefore, U3 L5 Activity Two or U3 L5 ActivityTwo is the proper class name.

The statement in print

Java distinguishes between lowercase and uppercase letters.

The program's print statements start with the little letter s. This is untrue.

The following are accurate statements:

"Enter two numbers," System.out.println;

"is a multiple of" + System.out.println(b + "" + a);

"Is not a multiple of" + System.out.println(b + "" + a);

Statements of declaration and input

Additionally, the input statements are incorrect, and variables a and b were incorrectly declared.

The appropriate answers are:

Integers a and b are equal to scan.nextInt();

The circumstance

The if statement is not formatted correctly.

The right response is: iif(b%a == 0)

Thus, the appropriate code is:

import scanner from java.util;

general class Main

(String[] args) public static void main

new Scanner(System.in) = Scanner scan;

"Enter two numbers," System.out.println;

I = scan.next int a

Int();

scan.nextInt(); int b;

if(b%a == 0){

"is a multiple of" + System.out.println(b + "" + a);

else{

"Is not a multiple of" + System.out.println(b + "" + a);

To know more about debugging click on the link:

https://brainly.com/question/13966274

#SPJ4