0

How can solve the 18.2 safety first in java

Safety first in java is not giving the excepted output.could anybody plz help with that one.

27th May 2022, 10:40 AM
Sunantha
5 odpowiedzi
+ 1
What is your code so that we can help debug?
27th May 2022, 10:42 AM
Justice
Justice - avatar
+ 1
Try to remove the blank space at the end of your output string. The output string needs to match exactly the one in the task description. Also remove the blank space between System and .out
27th May 2022, 11:10 AM
Lisa
Lisa - avatar
0
import java.util.Scanner; public class Program { public static void main(String[] args) { Scanner read=new Scanner(System.in); int password; do { password =read.nextInt(); System .out.println ("Write password "); }while(password!=8819); } }
27th May 2022, 10:44 AM
Sunantha
0
This is my code .test case 1 only completed
27th May 2022, 10:44 AM
Sunantha
0
Thank you Lisa. it's worked.
27th May 2022, 11:36 AM
Sunantha