Question: Each time readDouble is called, it creates another instance of Scanner reading from System.in. How would I refractor this to create only one instance of

Each time readDouble is called, it creates another instance of Scanner reading from System.in. How would I refractor this to create only one instance of Scanner that reads from System.in?
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
