結果
問題 | No.730 アルファベットパネル |
ユーザー |
|
提出日時 | 2019-09-15 08:30:28 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 540 bytes |
コンパイル時間 | 1,324 ms |
コンパイル使用メモリ | 170,748 KB |
実行使用メモリ | 6,944 KB |
最終ジャッジ日時 | 2024-07-06 22:39:31 |
合計ジャッジ時間 | 1,847 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 8 |
ソースコード
/** @file 730.cpp @title No.730 アルファベットパネル - yukicoder @url https://yukicoder.me/problems/no/730 **/ #include <bits/stdc++.h> using namespace std; typedef long long LL; #define ALL(obj) (obj).begin(), (obj).end() #define REP(i, N) for (int i = 0; i < (N); ++i) int main() { string S; cin >> S; sort(ALL(S)); size_t orgS = S.size(); S.erase(unique(ALL(S)), S.end()); size_t uniS = S.size(); if (orgS == uniS) { cout << "YES" << endl; } else { cout << "NO" << endl; } return 0; }