Skip to content

Commit

Permalink
feat(3.2.2): Finished U3_L2_Activity_Two
Browse files Browse the repository at this point in the history
  • Loading branch information
101zh committed Oct 9, 2023
1 parent 280cb2c commit d7990a0
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
{
"configurations": [
{
"type": "java",
"name": "U3_L2_Activity_Two",
"request": "launch",
"mainClass": "Unit3.U3_L2_Activity_Two",
"projectName": "my-app"
},
{
"type": "java",
"name": "U3_L2_Activity_One",
Expand Down
21 changes: 21 additions & 0 deletions src/main/java/Unit3/U3_L2_Activity_Two.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
package Unit3;

import java.util.Scanner;

public class U3_L2_Activity_Two {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);

double num1 = scanner.nextDouble();
double num2 = scanner.nextDouble();

if (num1 > num2) {
System.out.println(num1);
} else {
System.out.println(num2);
}
// System.out.println(Math.min(num1, num2));

scanner.close();
}
}

0 comments on commit d7990a0

Please sign in to comment.