Virtual contest is a way to take part in past contest, as close as possible to participation on time. It is supported only ACM-ICPC mode for virtual contests.
If you've seen these problems, a virtual contest is not for you - solve these problems in the archive.
If you just want to solve some problem from a contest, a virtual contest is not for you - solve this problem in the archive.
Never use someone else's code, read the tutorials or communicate with other person during a virtual contest.

No tag edit access

A. Mystical Mosaic

time limit per test

1 secondmemory limit per test

256 megabytesinput

standard inputoutput

standard outputThere is a rectangular grid of *n* rows of *m* initially-white cells each.

Arkady performed a certain number (possibly zero) of operations on it. In the *i*-th operation, a non-empty subset of rows *R*_{i} and a non-empty subset of columns *C*_{i} are chosen. For each row *r* in *R*_{i} and each column *c* in *C*_{i}, the intersection of row *r* and column *c* is coloured black.

There's another constraint: a row or a column can only be chosen at most once among all operations. In other words, it means that no pair of (*i*, *j*) (*i* < *j*) exists such that or , where denotes intersection of sets, and denotes the empty set.

You are to determine whether a valid sequence of operations exists that produces a given final grid.

Input

The first line contains two space-separated integers *n* and *m* (1 ≤ *n*, *m* ≤ 50) — the number of rows and columns of the grid, respectively.

Each of the following *n* lines contains a string of *m* characters, each being either '.' (denoting a white cell) or '#' (denoting a black cell), representing the desired setup.

Output

If the given grid can be achieved by any valid sequence of operations, output "Yes"; otherwise output "No" (both without quotes).

You can print each character in any case (upper or lower).

Examples

Input

5 8

.#.#..#.

.....#..

.#.#..#.

#.#....#

.....#..

Output

Yes

Input

5 5

..#..

..#..

#####

..#..

..#..

Output

No

Input

5 9

........#

#........

..##.#...

.......#.

....#.#.#

Output

No

Note

For the first example, the desired setup can be produced by 3 operations, as is shown below.

For the second example, the desired setup cannot be produced, since in order to colour the center row, the third row and all columns must be selected in one operation, but after that no column can be selected again, hence it won't be possible to colour the other cells in the center column.

Codeforces (c) Copyright 2010-2018 Mike Mirzayanov

The only programming contests Web 2.0 platform

Server time: Aug/19/2018 09:29:28 (f2).

Desktop version, switch to mobile version.

User lists

Name |
---|