Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class parkingLot
- {
- public static void main(String[] args)
- {
- Pizza a = new Pizza();
- System.out.println("Welcome to the parking lot. /n");
- System.out.println("The current time is insert_time_here. /n");
- System.out.println("Please enter your first name: /n");
- Scanner scan = new Scanner(System.in);
- a.name = scan.next();
- scan.nextLine();
- System.out.println("Please take your ticket, " + a.name + "." + "/n");
- //At this point, the system will have printed a ticket with the time that the user entered, and the users name
- System.out.println("Enter any alphabet character when you return /n");
- a.new = stuff.next();
- stuff.nextLine();
- System.out.println("=========================================================================" + "/n");
- System.out.println("The current time is insert_time_here. /n");
- System.out.println("Thank you for parking here, your total time parked is blank_variable");
- //blank_variable would be the result of return time - entered time
- //if blank_variable < 1hr, cost = $10
- //if 1hr < blank_variable < 2hrs, cost = $15
- //if 2hrs < blank_variable < 3hrs, cost = $18
- //if blank_variable > 3hrs, cost = $20
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement