fork download
  1. #include <iostream>
  2. #include <string>
  3. #include <thread>
  4. #include <chrono>
  5.  
  6. using namespace std;
  7.  
  8. void showHeart() {
  9. bool big = false;
  10. for (int i = 0; i < 10; ++i) { // 10 циклов анимации
  11. system("cls");
  12. if (big) {
  13. cout << "\n\n ❤️\n";
  14. } else {
  15. cout << "\n\n ❤️\n";
  16. }
  17. big = !big;
  18. this_thread::sleep_for(chrono::milliseconds(500));
  19. }
  20. }
  21.  
  22. void showPoop() {
  23. system("cls");
  24. cout << "\n\n 💩\n";
  25. this_thread::sleep_for(chrono::seconds(2));
  26. }
  27.  
  28. int main() {
  29. string input;
  30. cout << "Введите дату (ДД.ММ.ГГГГ): ";
  31. cin >> input;
  32.  
  33. if (input == "29.01.2025") {
  34. showHeart();
  35. } else {
  36. showPoop();
  37. }
  38.  
  39. return 0;
  40. }
Success #stdin #stdout #stderr 0.01s 5320KB
stdin
Standard input is empty
stdout
Введите дату (ДД.ММ.ГГГГ): 

    💩
stderr
sh: 1: cls: not found