0

Please, where is this wrong?

Boiling Water You are making a program for a water sensor that should check if the water is boiling. Take the integer temperature in Celsius as input and output "Boiling" if the temperature is above or equal to 100. Output "Not boiling" if it's not. Sample Input 105 Sample Output Boiling import java.util.Scanner; public class Program { public static void main(String[] args) { //your code goes here Scanner sc=new Scanner(System.in); int age=sc.nextInt(); if(age <= 100) { System.out.println("not boiling"); } else if(age >= 100){ System.out.println(" boiling"); } } }

22nd Nov 2023, 2:55 PM
Wisnu Darmawan
Wisnu Darmawan - avatar
1 Odpowiedź
+ 4
Check your code what happens when the water is exactly 100 C and what is the requirement. When printing the output, make sure to use the exact same phrases what is in the task description, mind the capital letters and any extra whitespace.
22nd Nov 2023, 3:03 PM
Tibor Santa
Tibor Santa - avatar