Advertisement
rosenrusev

Problem 5 - The Biggest of Three Numbers

Mar 20th, 2014
223
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.83 KB | None | 0 0
  1. using System;
  2.  
  3. namespace TheBiggestOfThreeNumbers
  4. {
  5. class TheBiggestOfThreeNumbers
  6. {
  7. static void Main()
  8. {
  9. double a = double.Parse(Console.ReadLine());
  10. double b = double.Parse(Console.ReadLine());
  11. double c = double.Parse(Console.ReadLine());
  12.  
  13. if (a > b)
  14. {
  15. if (a > c)
  16. {
  17. Console.WriteLine("{0}", a);
  18. }
  19. }
  20. if (b > a)
  21. {
  22. if (b > c)
  23. {
  24. Console.WriteLine("{0}", b);
  25. }
  26. }
  27. if (c > a)
  28. {
  29. if (c > b)
  30. {
  31. Console.WriteLine("{0}", c);
  32. }
  33. }
  34. }
  35. }
  36. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement