You do not read the line as you want, just use the code below to make it work the way you want.
s1 = scan.next();
For more information see the link
EDIT:
If your input contains a string with spaces, you can do something like:
scan.nextLine();
s1 = scan.nextLine();
- nextDouble()
, , , , nextLine()
. newLine()
String , .