#include <bits/stdc++.h>
    using namespace std;
    #include <ext/pb_ds/assoc_container.hpp>
    #include <ext/pb_ds/tree_policy.hpp>
    using namespace __gnu_pbds;
     
    #define fast { ios :: sync_with_stdio(false); cin.tie(0); cout.tie(0); }
    #define pb push_back
    #define ll long long
     
    #define vi vector<int>
    #define vll vector<long long>
    #define mp make_pair 
    #define infi INT_MAX
    #define infl LONG_LONG_MAX
    #define infd LDBL_MAX
    #define f(i,a,b) for(ll i=a;i<b;i++)
    #define ff first
    #define ss second
    #define pll pair<ll,ll> 
    #define endl "\n"
    #define ALL(v) v.begin(),v.end()
    #define nl cout<<"\n";
    #define pr(x) cout<<x;
    #define pr1(x) cout<<x<<" ";
    #define pr2(x,y) cout<<x<<" "<<y;
    #define deb printf("*****************************\n");
    #define idk printf("idk idk ! \n");
    #define hi printf("hi ! \n");
    #define bye printf("bye bye ! \n");
    #define o_set(ll) tree<ll, null_type,less<ll>, rb_tree_tag,tree_order_statistics_node_update>
    #define number_of_set_bits  __builtin_popcountll  
    #define ld long double 
    //template<typename T>
    //#define o_set(T) tree<T, null_type,less<T>, rb_tree_tag,tree_order_statistics_node_update>
    //member functions :
    //1. order_of_key(k) : number of elements strictly lesser than k
    //2. find_by_order(k) : k-th element in the set
     
     
 
 
 
     int main() 
    {
        fast
        //#ifndef ONLINE_JUDGE
        //freopen("input.txt", "r", stdin);
        //freopen("output.txt", "w", stdout);
        //#endif // ONLINE_JUDGE
        
     
        ll ntc=1;
     //   cin>>ntc;
     
        f(ks,1,ntc+1)
        {
          //cout<<"Case #"<<i<<": ";
         ll n; cin>>n;
         
         map<string,int> a,b;
         a.clear(), b.clear();
         bool ans = false; string print = "";
         f(i,0,n){
             string s; cin>>s;
            if(s[0] == '!'){
                string p = s.substr(1);
                if(a.count(p)) {
                    ans = true;
                    print = p;
                    break;
                }
                b[p]++;
            } else {
                if(b.count(s)){
                    ans = true; 
                    print = s;
                    break;
                }
                a[s]++;
            }
         }
         if(ans) cout<<print<<endl;
         else cout<<"satisfiable"<<endl;
        }
     
        return 0;
    }
#include <bits/stdc++.h>

using namespace std;

long long int in[200007];
long long int ou[200007];
char s[27];

int main()
{
    long long int i, n, j, pin=0, pou=0, x, y;
    cin >> n;
    for(i=0; i<n; i++){
        cin >> s;
        x=1;
        y=0;
        for(j=0; j<strlen(s); j++){
            if(s[j]!='!'){
                y+=(s[j]-'a'+1)*x;
                x*=30;
            }
        }
        if(s[0]=='!'){
            ou[pou]=y;
            pou++;
        }
        else{
            in[pin]=y;
            pin++;
        }
    }
    sort(in, in+pin);
    sort(ou, ou+pou);
    for(x=0, y=0; (x<pin)&&(y<pou);){
        if(in[x]==ou[y]){
            break;
        }
        if(x==pin-1){
            y++;
            continue;
        }
        if(y==pou-1){
            x++;
            continue;
        }
        if(in[x]<ou[y]){
            x++;
        }
        else{
            y++;
        }
    }
    if(in[x]==ou[y]){
        while(in[x]){
            cout << (char)(in[x]%30-1+'a');
            in[x]/=30;
        }
        cout << '\n';
    }
    else{
        cout << "satisfiable\n";
    }
    return 0;
}
