|
@@ -1,5 +1,23 @@
|
1
|
1
|
package io.zipcoder.casino;
|
2
|
2
|
|
3
|
3
|
|
|
4
|
+import java.util.Scanner;
|
|
5
|
+
|
4
|
6
|
public class Casino {
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+ public static void main(String[] args){
|
|
10
|
+ Player player = createPlayer();
|
|
11
|
+
|
|
12
|
+ }
|
|
13
|
+
|
|
14
|
+ public static Player createPlayer(){
|
|
15
|
+ System.out.println("What is your name player?");
|
|
16
|
+ Scanner playerInput = new Scanner(System.in);
|
|
17
|
+ String playerName = playerInput.nextLine();
|
|
18
|
+ System.out.println("How much money do you have?");
|
|
19
|
+ double startingMoney = playerInput.nextDouble();
|
|
20
|
+ //System.out.println(playerName + ": " + startingMoney);
|
|
21
|
+ return new Player(playerName, startingMoney);
|
|
22
|
+ }
|
5
|
23
|
}
|