fork download
  1. #include <iostream>
  2. #include <cmath>
  3. using namespace std;
  4.  
  5. int main() {
  6. float x, y;
  7. cin >> x >> y;
  8. if (x >= 0) {
  9. if (y >= 0) {
  10. if ((y < 1) && (x - 1 < y)) {
  11. cout << "YES";
  12. } else {
  13. cout << "NO";
  14. }
  15. }
  16. if (y < 0) {
  17. if (pow(x, 2) + pow(y, 2) < 1) {
  18. cout << "YES";
  19. } else {
  20. cout << "NO";
  21. }
  22. }
  23. } else {
  24. cout << "NO";
  25. }
  26. }
  27.  
Success #stdin #stdout 0s 4412KB
stdin
Standard input is empty
stdout
NO