diff options
| author | mo <mo.khan@gmail.com> | 2019-06-02 22:05:13 -0600 |
|---|---|---|
| committer | mo <mo.khan@gmail.com> | 2019-06-02 22:05:13 -0600 |
| commit | 44e29be9318ede77de14dca25c4cedd608045c07 (patch) | |
| tree | a2645b39f4ddc2c1b26ed04e5713a776a6da513a /src | |
| parent | b754fe0ae62308ecfd9464b824e90bdb1a147380 (diff) | |
update main main to choose which exercise to run
Diffstat (limited to 'src')
| -rw-r--r-- | src/App.java | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/src/App.java b/src/App.java index f7195fe..16c2a41 100644 --- a/src/App.java +++ b/src/App.java @@ -1,7 +1,22 @@ package ca.mokhan.comp268; +import Q1.*; +import java.util.Scanner; + public class App { public static void main(String[] args) { - System.out.println("Hello World!"); + Scanner in = new Scanner(System.in); + while (true) { + System.out.println("Choose exercise: (1-10)"); + switch (in.nextInt()) { + case 1: + Q1.ReversedSentence.main(args); + break; + default: + System.out.println("Bye"); + System.exit(0); + break; + } + } } } |
