#include #include #include using namespace std; int main() { int N; cin >> N; vector S(N); for (int i = 0; i < N; ++i) { cin >> S[i]; } set compound_words; for (int i = 0; i < N; ++i) { for (int j = 0; j < N; ++j) { if (i != j) { compound_words.insert(S[i] + S[j]); } } } cout << compound_words.size() << endl; return 0; }