Advertisement
kdterziev

Untitled

Feb 9th, 2016
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.01 KB | None | 0 0
  1. using System;
  2.  
  3.  
  4. namespace ConsoleApplication5
  5. {
  6. class Program
  7. {
  8. static void Main(string[] args)
  9. {
  10. var h = int.Parse(Console.ReadLine());
  11. var x1 = 0;
  12. var y1 = x1;
  13. var x2 = h;
  14. var y2 = h;
  15. var x3 = (2 * h);
  16. var y3 = (4 * h);
  17. var x4 = (3 * h);
  18. var y4 = h;
  19. var x = int.Parse(Console.ReadLine());
  20. var y = int.Parse(Console.ReadLine());
  21.  
  22. if (((x > x2) && (y > y2) && (x < x3) && (y < y3)) || ((x > x1) && (y > y1) && (x < x4) && (y < y4)))
  23. {
  24. Console.WriteLine("inside");
  25. }
  26. else if (((x == x2) && (y == y2) && (x == x3) && (y == y3)) || ((x == x1) && (y == y1) && (x == x4) && (y == y4)))
  27. {
  28. Console.WriteLine("Boreder");
  29. }
  30. else
  31. {
  32. Console.WriteLine("outside");
  33. }
  34.  
  35. }
  36. }
  37. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement