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

int main() {
	int n;
	cin >> n;
	map<string, int> m1, m2;
	string ans = "satisfiable";
	for(int i=0; i<n; i++){
	    string s;
	    cin >> s;
	    if(s[0] == '!'){
	        s = s.substr(1, s.size() - 1);
	        if(m2.count(s))
	            ans = s;
	        m1[s]++;
	    }else{
	        if(m1.count(s))
	            ans = s;
	        m2[s]++;
	    }
	}
	cout << ans;
	return 0;
}
#include <bits/stdc++.h>
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
using namespace std;
using ll = long long int;
template<class T> void chmin(T& a, T b) { if (a > b) { a = b; } }
template<class T> void chmax(T& a, T b) { if (a < b) { a = b; } }

int main() {
  int N;
  cin >> N;

  unordered_map<string, int> mp;

  rep(i, N) {
    string S;
    cin >> S;

    if (S[0] == '!') {
      if (mp.find(S.substr(1, S.size() - 1)) != mp.end()) {
        cout << S.substr(1, S.size() - 1) << endl;
        return 0;
      } else {
        mp[S] = i;
      }
    } else {
      if (mp.find("!" + S) != mp.end()) {
        cout << S << endl;
        return 0;
      } else {
        mp[S] = i;
      }
    }
  }
  cout << "satisfiable" << endl;
}