diff --git a/61/solutie.cpp b/61/solutie.cpp new file mode 100644 index 0000000..aa961b3 --- /dev/null +++ b/61/solutie.cpp @@ -0,0 +1,24 @@ +#include + +using namespace std; + +int main() { + int n, k, offset=0; + cin >> n >> k; + for (int i = 0; i < n; i++) { + for (int j = 0; j < offset; j++) { + cout << "1"; + } + for (int j = 0; j < n-k; j++) { + if (offset + j < n) { + cout << "0"; + } + } + for (int j = 0; j < k-offset; j++) { + cout << "1"; + } + cout << endl; + offset++; + } + return 0; +}