#include <bits/stdc++.h>
using namespace std;
template <template <class> class pred, typename T = double>
void apply(vector<vector<T>> & m, const T & rhs) {
for (auto & i : m)
for (auto & j : i)
j = pred<T>()(j, rhs);
}
int main() {
vector<vector<double>> m(2, vector<double>(2));
apply<minus>(m, 1.0);
for (auto & i : m)
for (auto & j : i)
cout << j << endl;
return 0;
}
I2luY2x1ZGUgPGJpdHMvc3RkYysrLmg+CnVzaW5nIG5hbWVzcGFjZSBzdGQ7Cgp0ZW1wbGF0ZSA8dGVtcGxhdGUgPGNsYXNzPiBjbGFzcyBwcmVkLCB0eXBlbmFtZSBUID0gZG91YmxlPgp2b2lkIGFwcGx5KHZlY3Rvcjx2ZWN0b3I8VD4+ICYgbSwgY29uc3QgVCAmIHJocykgewoJZm9yIChhdXRvICYgaSA6IG0pCgkJZm9yIChhdXRvICYgaiA6IGkpCgkJCWogPSBwcmVkPFQ+KCkoaiwgcmhzKTsKfQoKaW50IG1haW4oKSB7Cgl2ZWN0b3I8dmVjdG9yPGRvdWJsZT4+IG0oMiwgdmVjdG9yPGRvdWJsZT4oMikpOwoJYXBwbHk8bWludXM+KG0sIDEuMCk7CgoJZm9yIChhdXRvICYgaSA6IG0pCgkJZm9yIChhdXRvICYgaiA6IGkpCgkJCWNvdXQgPDwgaiA8PCBlbmRsOwoKCXJldHVybiAwOwp9