#include using namespace std; int calc(int x) { return x / 10 + x % 10; } int main() { int A, B, C; cin >> A >> B >> C; bool ok = false; int res = 100000; for (int i = 0; i <= A; i++) { for (int j = 0; j <= B; j++) { int v = i + j * 10; for (int k = 1; k <= v; k++) { if (A - i + B - j + calc(v - k) == C) { ok = true; res = min(res, k); } } } } if (!ok) cout << "Impossible" << endl; else cout << res << endl; return 0; }