fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. for (int i = 1; i <= 4; i++) {
  6. for (int j = 1; j <= i; j++) {
  7. if (j % 2 == 0) {
  8. cout << "*";
  9. break;
  10. }
  11. }
  12. }
  13. }
Success #stdin #stdout 0.01s 5292KB
stdin
Standard input is empty
stdout
***