12 years, 3 months ago
Highlights
12 years, 3 months ago
Yes you are right you need to call close. Another approach: public class InputManager { private final Scanner scanner; public InputManager() { scanner = new Scanner(Syste…
12 years, 3 months ago
Best practice would be to re-use the same scanner instance. If the menu() and info() method must remain static then you can do something like this: private static final S…
12 years, 3 months ago
13 years, 5 months ago
13 years, 5 months ago
Latest Activity
See all in DiscussionsYes you are right you need to call close. Another approach: public class InputManager { private final Scanner scanner; …
12 years, 3 months ago
Best practice would be to re-use the same scanner instance. If the menu() and info() method must remain static then …
12 years, 3 months ago
I see, it's just that I read somewhere that (and I semi-quote it) "If you need to use instanceof, it …
13 years, 5 months ago