結果
| 問題 | No.3497 Sign up for traP |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2026-04-17 21:11:34 |
| 言語 | C++23 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
AC
|
| 実行時間 | 2 ms / 2,000 ms |
| コード長 | 1,709 bytes |
| 記録 | |
| コンパイル時間 | 4,983 ms |
| コンパイル使用メモリ | 374,212 KB |
| 実行使用メモリ | 6,400 KB |
| 最終ジャッジ日時 | 2026-04-17 21:11:46 |
| 合計ジャッジ時間 | 11,389 ms |
|
ジャッジサーバーID (参考情報) |
judge3_1 / judge2_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 18 |
ソースコード
// Compile: g++ -std=c++20 -O2 -Wall -I$HOME/ctf/tools/ac-library -DLOCAL -o sol sol.cpp
// Or: make sol (uses Makefile in this dir)
// Run: ./sol < in.txt
#include <bits/stdc++.h>
#include <atcoder/all>
using namespace std;
using namespace atcoder;
using ll = long long;
using ull = unsigned long long;
using vi = vector<int>;
using vll = vector<ll>;
using vvi = vector<vi>;
using vvll = vector<vll>;
using pii = pair<int,int>;
using pll = pair<ll,ll>;
#define rep(i,n) for(ll i=0;i<(ll)(n);++i)
#define rep2(i,a,b) for(ll i=(ll)(a);i<(ll)(b);++i)
#define all(x) (x).begin(),(x).end()
#define rall(x) (x).rbegin(),(x).rend()
#define sz(x) ((ll)(x).size())
template<class T> bool chmin(T&a,const T&b){if(b<a){a=b;return true;}return false;}
template<class T> bool chmax(T&a,const T&b){if(a<b){a=b;return true;}return false;}
#ifdef LOCAL
#define dbg(x) cerr<<#x<<" = "<<(x)<<endl
#else
#define dbg(x)
#endif
using mint = modint998244353;
// using mint = modint1000000007;
int main(){
ios::sync_with_stdio(false);
cin.tie(nullptr);
string s;
cin >> s;
if(sz(s) > 32) {
cout << "400" << endl;
return 0;
}
if(s[0] == '-' || s[0] == '_') {
cout << "400" << endl;
return 0;
}
if(s[sz(s)-1] == '-' || s[sz(s)-1] == '_') {
cout << "400" << endl;
return 0;
}
bool is_200 = true;
for (int i = 0; i < sz(s); i++) {
int now = s[i];
if (!(now==45||now==95||(48<=now&&now<=57)|| (65<=now&&now<=90)|| (97<=now&&now<=122))) {
is_200 = false;
}
}
if (is_200) {
cout << "200" << endl;
} else {
cout << "400" << endl;
}
return 0;
}