#include <bits/stdc++.h>
using namespace std;
int main() {
  int t;
  t = 1;
  while (t--) {
    long long n, i, j, w, h, count = 0, sum = 0, total, k, T, m;
    string s;
    cin >> n >> m;
    if (n == 0 && m != 0) {
      cout << "Impossible";
    } else if (m == 0) {
      cout << n << " " << n;
    } else if (n == 1) {
      if (m > 0) {
        cout << n + m - 1 << " " << n + m - 1;
      } else
        cout << n << " " << n;
    } else {
      if (n > m) {
        cout << n << " " << n + m - 1;
      } else {
        cout << m << " " << n + m - 1;
      }
    }
  }
}
