You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
22 lines
412 B
22 lines
412 B
#include <algorithm>
|
|
#include <iostream>
|
|
using namespace std;
|
|
|
|
int main() {
|
|
int n;
|
|
cin >> n;
|
|
int flower_array[n];
|
|
for (int i = 0; i < n; i++) {
|
|
cin >> flower_array[i];
|
|
}
|
|
for (int i = 0; i < n - 1; i++) {
|
|
for (int j = 0; j < n - i - 1; j++) {
|
|
int k = j + i;
|
|
for (int l = 1; l <= k; l++) {
|
|
cout << flower_array[l] << " ";
|
|
}
|
|
cout << endl;
|
|
}
|
|
}
|
|
return 0;
|
|
}
|
|
|