
Best Answer Chanito, 08 November 2015 - 10:15 AM
Got it working, here is the code:
using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace The_Switch_Statement_1 { class Program { static void Main(string[] args) { Console.WriteLine("Är ditt namn Yulieth (Ja/Kanske/Nej)"); //Prints string input = Console.ReadLine(); //Reads the user input switch (input.ToLower()) //Converts the input into lowercase { case "ja": //Checks if it is true case "kanske": Console.WriteLine("Hej Yulieth!"); //If it is true, WriteLine "Bra!" break; //If it is NOT true, continue to the next option case "nej": Console.WriteLine("Stick då!"); break; default: Console.WriteLine("Kan du inte Svenska eller?"); break; } } } }Go to the full post
