h, w = map(int, input().split())
sum = 0
for i in range(h):
    a = input()
    sum += a.count('#')
if sum == h + w - 1:
    print("Possible")
else:
    print("Impossible")
92630295c84bf7af05f35a1de7a75adbc941e0a4
<mask token>

<mask token>
for i in range(h):
    a = input()
    sum += a.count('#')
if sum == h + w - 1:
    print('Possible')
else:
    print('Impossible')

h, w = map(int, input().split())
sum = 0
for i in range(h):
    a = input()
    sum += a.count('#')
if sum == h + w - 1:
    print('Possible')
else:
    print('Impossible')

h, w = map(int, input().split())
sum = 0
for i in range(h):
    a = input()
    sum += a.count('#')
if sum == h + w - 1:
    print("Possible")
else:
    print("Impossible")