import std;

// dfmt off
T lread(T=long)(){return readln.chomp.to!T;}
T[] lreads(T=long)(long n){return generate(()=>readln.chomp.to!T()).take(n).array;}
T[] aryread(T=long)(){return readln.split.to!(T[]);}
void arywrite(T=long)(T[] ary){ary.map!(text).join(' ').writeln;}
void scan(TList...)(ref TList Args){auto line = readln.split;
foreach (i,T;TList){T val=line[i].to!(T);Args[i]=val;}}
void dprint(TList...)(TList Args){debug{auto s=new string[](TList.length);
static foreach(i,a;Args) s[i]=text(a);s.map!(text).join(' ').writeln;}}
alias sread=()=>readln.chomp();enum MOD =10^^9+7;
alias PQueue(T,alias less="a<b") = BinaryHeap!(Array!T,less);
// dfmt on

void main()
{
    long N = lread();
    auto S = new string[](N);
    foreach (i; 0 .. N)
        S[i] = sread();
    auto left = new long[](N);
    auto right = new long[](N);
    foreach (i; 0 .. N)
    {
        foreach (j; 0 .. S[i].length)
        {
            if (S[i][j] == '(')
                right[i]++;
            if (S[i][j] == ')')
                right[i] = max(0, right[i] - 1);
        }
        foreach_reverse (j; 0 .. S[i].length)
        {
            if (S[i][j] == ')')
                left[i]++;
            if (S[i][j] == '(')
                left[i] = max(0, left[i] - 1);
        }
    }
    right[] *= -1;
    zip(left, right).sort();
    right[] *= -1;
    long r;
    foreach (i; 0 .. N)
    {
        if (r < left[i])
        {
            writeln("No");
            dprint(r, left[i], right[i]);
            return;
        }
        r -= left[i];
        r += right[i];
        dprint(r, left[i], right[i]);
    }
    writeln(r == 0 ? "Yes" : "No");
}
