M0Hk

SummerOutfit

Feb 26th, 2020
190
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 2.11 KB | None | 0 0
  1. using System;
  2.  
  3. namespace _03.SummerOutfit
  4. {
  5.     class Program
  6.     {
  7.         static void Main(string[] args)
  8.         {
  9.             int degrees = int.Parse(Console.ReadLine());
  10.             string timeOfDay = Console.ReadLine();
  11.             string outfit = "";
  12.             string shoes = "";
  13.  
  14.             if (degrees >= 10 && degrees <= 18)
  15.             {
  16.                 if (timeOfDay == "Morning")
  17.                 {
  18.                     outfit = "Sweatshirt";
  19.                     shoes = "Sneakers";
  20.                 }
  21.                 else if (timeOfDay == "Afternoon")
  22.                 {
  23.                     outfit = "Shirt";
  24.                     shoes = "Moccasins";
  25.                 }
  26.                 else if (timeOfDay == "Evening")
  27.                 {
  28.                     outfit = "Shirt";
  29.                     shoes = "Moccasins";
  30.                 }
  31.             }
  32.             else if (degrees > 18 && degrees <= 24)
  33.             {
  34.                 if (timeOfDay == "Morning")
  35.                 {
  36.                     outfit = "Shirt";
  37.                     shoes = "Moccasins";
  38.                 }
  39.                 else if (timeOfDay == "Afternoon")
  40.                 {
  41.                     outfit = "T-Shirt";
  42.                     shoes = "Sandals";
  43.                 }
  44.                 else if (timeOfDay == "Evening")
  45.                 {
  46.                     outfit = "Shirt";
  47.                     shoes = "Moccasins";
  48.                 }
  49.             }
  50.             else if (degrees >= 25)
  51.             {
  52.                 if (timeOfDay == "Morning")
  53.                 {
  54.                     outfit = "T-Shirt";
  55.                     shoes = "Sandals";
  56.                 }
  57.                 else if (timeOfDay == "Afternoon")
  58.                 {
  59.                     outfit = "Swim Suit";
  60.                     shoes = "Barefoot";
  61.                 }
  62.                 else if (timeOfDay == "Evening")
  63.                 {
  64.                     outfit = "Shirt";
  65.                     shoes = "Moccasins";
  66.                 }
  67.             }
  68.             Console.WriteLine($"It's {degrees} degrees, get your {outfit} and {shoes}.");
  69.         }
  70.     }
  71. }
Advertisement
Add Comment
Please, Sign In to add comment