結果
| 問題 | No.2737 Compound Word |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2024-05-30 22:50:36 |
| 言語 | C++17 (gcc 15.2.0 + boost 1.90.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 414 bytes |
| 記録 | |
| コンパイル時間 | 1,209 ms |
| コンパイル使用メモリ | 217,836 KB |
| 実行使用メモリ | 10,228 KB |
| 最終ジャッジ日時 | 2026-07-04 19:29:23 |
| 合計ジャッジ時間 | 2,466 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge3_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 27 |
ソースコード
#include<bits/stdc++.h>
#define pt printf(">>>")
#define mid (((l)+(r))/2)
using namespace std;
typedef long long ll;
typedef long double ld;
const ll N=1e6+10,inf=1e18+10,mod=1e9+7;
ll n;
string s[60];
set<string> ss;
int main(){
cin >> n;
for(ll i=1;i<=n;i++)cin >> s[i];
for(ll i=1;i<=n;i++){
for(ll j=1;j<=n;j++){
if(s[i]==s[j])continue;
ss.insert(s[i]+s[j]);
}
}
cout << ss.size();
return 0;
}