Advertisement
Guest User

Untitled

a guest
Mar 31st, 2015
216
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.80 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Text;
  4. using System.IO.Ports;
  5. using System.Threading;
  6. namespace Hello_CS_World
  7. {
  8. class Program
  9. {
  10. static void Main(string[] args)
  11. {
  12. bool _continue = true ;
  13. string message;
  14. StringComparer stringComparer = StringComparer.OrdinalIgnoreCase;
  15. // Display title and prompt line on console
  16. Console.WriteLine("Hello C# World");
  17. Console.WriteLine ("Type QUIT to Exit");
  18. // Loop reading in lines from keyboard until user types "quit"
  19. while (_continue)
  20. {
  21. message = Console.ReadLine();
  22. if (stringComparer.Equals("quit", message))
  23. {
  24. _continue = false;
  25. }
  26. }
  27. }
  28. }
  29. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement