Odd error in my Java program

前端 未结 2 1552
孤独总比滥情好
孤独总比滥情好 2021-01-29 06:18

I have a Java program that is designed to take an input of customers, then run a loop for each. Then the user has 3 choices to input: clowns, safari sam, or music caravan. I jus

2条回答
  •  孤独总比滥情好
    2021-01-29 06:57

    For reading String provided by the user in console you have to use .nextLine() So try by using this -

     String service_type = new_scan.nextLine();
    

    This should store the value of whatever you are providing in the console to the String "service_type".

提交回复
热议问题