Fox Ciel has a board with n rows and n columns. So, the board consists of n × n cells. Each cell contains either a symbol '.', or a symbol '#'.

A cross on the board is a connected set of exactly five cells of the board that looks like a cross. The picture below shows how it looks.

<image>

Ciel wants to draw several (may be zero) crosses on the board. Each cross must cover exactly five cells with symbols '#', and any cell with symbol '#' must belong to some cross. No two crosses can share a cell.

Please, tell Ciel if she can draw the crosses in the described way.

Input

The first line contains an integer n (3 ≤ n ≤ 100) — the size of the board.

Each of the next n lines describes one row of the board. The i-th line describes the i-th row of the board and consists of n characters. Each character is either a symbol '.', or a symbol '#'.

Output

Output a single line with "YES" if Ciel can draw the crosses in the described way. Otherwise output a single line with "NO".

Examples

Input

5
.#...
####.
.####
...#.
.....


Output

YES


Input

4
####
####
####
####


Output

NO


Input

6
.#....
####..
.####.
.#.##.
######
.#..#.


Output

YES


Input

6
.#..#.
######
.####.
.####.
######
.#..#.


Output

NO


Input

3
...
...
...


Output

YES

Note

In example 1, you can draw two crosses. The picture below shows what they look like.

<image>

In example 2, the board contains 16 cells with '#', but each cross contains 5. Since 16 is not a multiple of 5, so it's impossible to cover all.
import java.io.*;
import java.math.*;
import java.util.*;
import java.lang.*;

public class Main{ 

    public static InputStream inputStream = System.in;
    public static OutputStream outputStream = System.out;
    public static FastReader in = new FastReader(inputStream);
    public static PrintWriter out = new PrintWriter(outputStream);

    public static void main(String[] args)throws java.lang.Exception{
        new Main().run();
        out.close();
    }
    
    int n;
    int m;
    int t;
    char[][] a;
    
    void run()throws java.lang.Exception{
        int n = in.nextInt();
        a = new char[n][n];
        int rem = 0;
        for(int i=0; i<n; i++){
            a[i] = in.nextLine().toCharArray();
            for(int j=0; j<n; j++){
                if(a[i][j] == '#'){
                    rem++;
                }
            }
        }
        int stx = n;
        int sty = n;
        for(int i=1; i<n; i++){
            boolean d = false;
            for(int j=1; j<n; j++){
                if(a[i][j] != '#'){
                    continue;
                }
                char bef = a[i][j-1];
                char ab = a[i-1][j];
                char dg = a[i-1][j-1];
                if(bef==ab && ab=='#' && dg=='.'){
                    stx = i;
                    sty = j;
                    d = true;
                    break;
                }
            }
            if(d){
                break;
            }
        }
        if(rem==0){
            System.out.println("YES");
            System.exit(0);
        }
        if(stx==n && sty==n){
            System.out.println("NO");
            System.exit(0);
        }
        boolean done = false;
        while(true){
            if(a[stx+1][sty]!= '#' || a[stx][sty+1] != '#'){
                System.out.println("NO");
                done = true;
                break;
            }
            a[stx+1][sty] = a[stx][sty+1] = a[stx-1][sty] = 
                    a[stx][sty-1] = a[stx][sty] = '-';
            rem -= 5;
            if(rem==0){
                break;
            }
            boolean d = false;
            int lx = stx;
            int ly = sty;
            for(int i=stx; i<n; i++){
                for(int j=1; j<n; j++){
                    if(a[i][j] != '#'){
                        continue;
                    }
                    char bef = a[i][j-1];
                    char ab = a[i-1][j];
                    char dg = a[i-1][j-1];
                    if(bef==ab && ab=='#' && dg!='#'){
                        stx = i;
                        sty = j;
                        d = true;
                        break;
                    }
                }
                if(d){
                    break;
                }
            }
            if(lx==stx && ly==sty){
                done = true;
                System.out.println("NO");
                break;
            }
        }
        if(!done){
            System.out.println("YES");
        }
    }
    
    int gcd(int a, int b){
//      System.out.println(a + " " + b);
        if(b==0){
            return a;
        }
        return gcd(b, a%b);
    }
}

class Obj implements Comparable<Obj>{
    int x;
    int y;
    public Obj(int a, int b){
        x = a;
        y = b;
    }
    
    public int compareTo(Obj that){
        return Integer.valueOf(x).compareTo(that.x);
    }
}


class FastReader{
    private boolean finished = false;

    private InputStream stream;
    private byte[] buf = new byte[1024];
    private int curChar;
    private int numChars;
    private SpaceCharFilter filter;

    public FastReader(InputStream stream){
        this.stream = stream;
    }

    public int read(){
        if (numChars == -1){
            throw new InputMismatchException ();
        }
        if (curChar >= numChars){
            curChar = 0;
            try{
                numChars = stream.read (buf);
            } catch (IOException e){
                throw new InputMismatchException ();
            }
            if (numChars <= 0){
                return -1;
            }
        }
        return buf[curChar++];
    }

    public int peek(){
        if (numChars == -1){
            return -1;
        }
        if (curChar >= numChars){
            curChar = 0;
            try{
                numChars = stream.read (buf);
            } catch (IOException e){
                return -1;
            }
            if (numChars <= 0){
                return -1;
            }
        }
        return buf[curChar];
    }

    public int nextInt(){
        int c = read ();
        while (isSpaceChar (c))
            c = read ();
        int sgn = 1;
        if (c == '-'){
            sgn = -1;
            c = read ();
        }
        int res = 0;
        do{
            if(c==','){
                c = read();
            }
            if (c < '0' || c > '9'){
                throw new InputMismatchException ();
            }
            res *= 10;
            res += c - '0';
            c = read ();
        } while (!isSpaceChar (c));
        return res * sgn;
    }

    public long nextLong(){
        int c = read ();
        while (isSpaceChar (c))
            c = read ();
        int sgn = 1;
        if (c == '-'){
            sgn = -1;
            c = read ();
        }
        long res = 0;
        do{
            if (c < '0' || c > '9'){
                throw new InputMismatchException ();
            }
            res *= 10;
            res += c - '0';
            c = read ();
        } while (!isSpaceChar (c));
        return res * sgn;
    }

    public String nextString(){
        int c = read ();
        while (isSpaceChar (c))
            c = read ();
        StringBuilder res = new StringBuilder ();
        do{
            res.appendCodePoint (c);
            c = read ();
        } while (!isSpaceChar (c));
        return res.toString ();
    }

    public boolean isSpaceChar(int c){
        if (filter != null){
            return filter.isSpaceChar (c);
        }
        return isWhitespace (c);
    }

    public static boolean isWhitespace(int c){
        return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
    }

    private String readLine0(){
        StringBuilder buf = new StringBuilder ();
        int c = read ();
        while (c != '\n' && c != -1){
            if (c != '\r'){
                buf.appendCodePoint (c);
            }
            c = read ();
        }
        return buf.toString ();
    }

    public String nextLine(){
        String s = readLine0 ();
        while (s.trim ().length () == 0)
            s = readLine0 ();
        return s;
    }

    public String nextLine(boolean ignoreEmptyLines){
        if (ignoreEmptyLines){
            return nextLine ();
        }else{
            return readLine0 ();
        }
    }

    public BigInteger nextBigInteger(){
        try{
            return new BigInteger (nextString ());
        } catch (NumberFormatException e){
            throw new InputMismatchException ();
        }
    }

    public char nextCharacter(){
        int c = read ();
        while (isSpaceChar (c))
            c = read ();
        return (char) c;
    }

    public double nextDouble(){
        int c = read ();
        while (isSpaceChar (c))
            c = read ();
        int sgn = 1;
        if (c == '-'){
            sgn = -1;
            c = read ();
        }
        double res = 0;
        while (!isSpaceChar (c) && c != '.'){
            if (c == 'e' || c == 'E'){
                return res * Math.pow (10, nextInt ());
            }
            if (c < '0' || c > '9'){
                throw new InputMismatchException ();
            }
            res *= 10;
            res += c - '0';
            c = read ();
        }
        if (c == '.'){
            c = read ();
            double m = 1;
            while (!isSpaceChar (c)){
                if (c == 'e' || c == 'E'){
                    return res * Math.pow (10, nextInt ());
                }
                if (c < '0' || c > '9'){
                    throw new InputMismatchException ();
                }
                m /= 10;
                res += (c - '0') * m;
                c = read ();
            }
        }
        return res * sgn;
    }

    public boolean isExhausted(){
        int value;
        while (isSpaceChar (value = peek ()) && value != -1)
            read ();
        return value == -1;
    }

    public String next(){
        return nextString ();
    }

    public SpaceCharFilter getFilter(){
        return filter;
    }

    public void setFilter(SpaceCharFilter filter){
        this.filter = filter;
    }

    public interface SpaceCharFilter{
        public boolean isSpaceChar(int ch);
    }
}