fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int a, b;
  6. cin >> a >> b;
  7. //cout << b;
  8. int copyB = b;
  9. b /=10;
  10. if (b == a) {
  11. cout << "DA!";
  12. //cout << b;
  13.  
  14. }else if (((copyB % 10)+(copyB/ 10 % 10)*10)==a) {
  15. //cout << copyB;
  16. cout << "DA!";
  17.  
  18. }else{
  19. cout << "NU!";
  20. }
  21. return 0;
  22. }
Success #stdin #stdout 0.01s 5284KB
stdin
23 123
stdout
DA!