Advertisement
Guest User

Untitled

a guest
Jul 18th, 2018
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.03 KB | None | 0 0
  1. using System;
  2.  
  3.  
  4. namespace _05.Matrix
  5. {
  6. class Program
  7. {
  8. static void Main(string[] args)
  9. {
  10. int a = int.Parse(Console.ReadLine());
  11. int b = int.Parse(Console.ReadLine());
  12. int c = int.Parse(Console.ReadLine());
  13. int d = int.Parse(Console.ReadLine());
  14.  
  15.  
  16.  
  17. for (int i = a; i <= b; i++)
  18. {
  19. for (int k = a; k <=b; k++)
  20. {
  21. for (int n = c; n <=d; n++)
  22. {
  23. for (int m = c; m <= d; m++)
  24. {
  25. if ( i + m == k + n && i != k && n !=m)
  26. {
  27. Console.WriteLine($"{i}{k}");
  28. Console.WriteLine($"{n}{m}");
  29. Console.WriteLine();
  30. }
  31. }
  32. }
  33. }
  34. }
  35.  
  36.  
  37. }
  38. }
  39. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement