#include <bits/stdc++.h>
using namespace std;

int main() {
    int64_t N;
    cin >> N;
    vector<string> S(N);
    for ( int64_t i = 0; i < N; ++i){
        cin >> S[i];
    }
    
    multiset<pair<int64_t,int64_t>> add,del;
    for ( int64_t i = 0; i < N; ++i){
        int64_t cur = 0, mi = 0;
        for ( auto c: S[i]) {
            if ( c == '(' ) ++cur;
            else --cur;
            mi = min(mi,cur);
        }
        if ( cur >= 0 ) add.insert({-mi,cur});
        else del.insert({-mi+cur,-cur});
    }
    
    int64_t cur = 0;
    bool possible = true;
    for ( auto p : add ) {
        // p.first の少ない方から読み込まれる
        if ( cur - p.first < 0 ) possible = false;
        else cur += p.second;
    }
    
    int64_t x = cur;
    cur = 0;
    for ( auto p : del ) {
           // p.first の少ない方から読み込まれる
           if ( cur - p.first < 0 ) possible = false;
           else cur += p.second;
    }
    
    if ( cur == x and possible ) cout << "Yes" << endl;
    else cout << "No" << endl;
    
    return 0;
}