Advertisement
Roadstar3

WeatherForeCast

Oct 17th, 2019
174
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.41 KB | None | 0 0
  1. import java.util.Scanner;
  2.  
  3. class WeatherForeCast {
  4.     public static void main(String[] args) {
  5.         Scanner scanner=new Scanner(System.in);
  6.  
  7.         String text = scanner.nextLine();
  8.        
  9.         if (text.equals("sunny"))
  10.         {
  11.             System.out.println("It's warm outside!");
  12.         }
  13.         else
  14.         {
  15.             System.out.println("It's cold outside!");
  16.         }
  17.  
  18.     }
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement