Advertisement
Spocoman

02. Summer Outfit

Nov 17th, 2021 (edited)
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.96 KB | None | 0 0
  1. using System;
  2.  
  3. namespace SummerOutfit
  4. {
  5.     class Program
  6.     {
  7.         static void Main(string[] args)
  8.         {
  9.             int degrees = int.Parse(Console.ReadLine());
  10.             string time = Console.ReadLine();
  11.             string outfit = "Shirt";
  12.             string shoes = "Moccasins";
  13.  
  14.             if (degrees >= 10 && degrees <= 18 && time == "Morning")
  15.             {
  16.                 outfit = "Sweatshirt";
  17.                 shoes = "Sneakers";
  18.             }
  19.             else if (degrees > 18 && degrees <= 24 && time == "Afternoon" || degrees > 24 && time == "Morning")
  20.             {
  21.                 outfit = "T-Shirt";
  22.                 shoes = "Sandals";
  23.             }
  24.             else if (degrees > 24 && time == "Afternoon")
  25.             {
  26.                 outfit = "Swim Suit";
  27.                 shoes = "Barefoot";
  28.             }
  29.  
  30.             Console.WriteLine($"It's {degrees} degrees, get your {outfit} and {shoes}.");
  31.         }
  32.     }
  33. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement