def solve(): V, X, Fo, Fi, Q, R = map(int, input().split()) if X + (Fi - Fo) * R > V or Fi * R - Fo * Q > 0: return 'Overflow' if Fi * R - Fo * Q < 0: return 'Zero' return 'Safe' T = int(input()) for i in range(T): print(solve())