#include using namespace std; int main(){ int N, M; cin >> N >> M; vector X(N), Y(M); for(int& x : X) cin >> x; for(int& y : Y) cin >> y; sort(Y.begin(), Y.end()); for(int x : X){ auto p = lower_bound(Y.begin(), Y.end(), x); if(p == Y.end()) puts("Infinity"); else cout << *p - x << '\n'; } }