Advertisement
Guest User

Untitled

a guest
Feb 25th, 2017
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 KB | None | 0 0
  1. #include <iostream>
  2.  
  3.  
  4. using namespace std;
  5. int main(){
  6. int k,n,m,x,y;
  7. while (k!=0){
  8. cin >> k;
  9. if (k==0){
  10. return 0;
  11. }
  12. cin >> n >> m;
  13. for (int i=0; i<k; i++){
  14. cin >> x >> y;
  15. if (y>m&&x>n){
  16. cout << "NE" << endl;
  17. }
  18. else if (y>m&&x<n){
  19. cout << "NO" << endl;
  20. }
  21. else if (y<m&&x>n){
  22. cout << "SE" << endl;
  23. }
  24. else if (y<m&&x<n){
  25. cout << "SO" << endl;
  26. }
  27. else {
  28. cout << "divisa" << endl;
  29. }
  30. }
  31. }
  32. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement