fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int a, b, c;
  6. cin >> a >> b >> c;
  7. if (b - a && c - b >= 2) {
  8. cout << "DA";
  9. } else {
  10. cout << "NU";
  11. }
  12. return 0;
  13. }
Success #stdin #stdout 0.01s 5268KB
stdin
2 3 5
17 18 20 -> NU
2 4 6 -> DA
4 4 6 -> NU
4 6 6 -> NU
13 15 17->DA
3 14 20->DA

20 20 20 -> NU
5 9 15 -> DA
2 4 8 --> DA**

stdout
DA