結果

問題 No.279 木の数え上げ
ユーザー sortreewsortreew
提出日時 2015-09-18 22:25:56
言語 C++11
(gcc 11.4.0)
結果
AC  
実行時間 21 ms / 2,000 ms
コード長 808 bytes
コンパイル時間 1,128 ms
コンパイル使用メモリ 144,400 KB
実行使用メモリ 5,092 KB
最終ジャッジ日時 2023-08-04 17:58:24
合計ジャッジ時間 2,312 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 2 ms
4,380 KB
testcase_01 AC 2 ms
4,376 KB
testcase_02 AC 1 ms
4,380 KB
testcase_03 AC 2 ms
4,380 KB
testcase_04 AC 2 ms
4,376 KB
testcase_05 AC 2 ms
4,376 KB
testcase_06 AC 2 ms
4,376 KB
testcase_07 AC 1 ms
4,376 KB
testcase_08 AC 2 ms
4,376 KB
testcase_09 AC 1 ms
4,376 KB
testcase_10 AC 19 ms
4,380 KB
testcase_11 AC 5 ms
4,376 KB
testcase_12 AC 14 ms
4,376 KB
testcase_13 AC 3 ms
4,380 KB
testcase_14 AC 21 ms
5,092 KB
testcase_15 AC 18 ms
4,380 KB
testcase_16 AC 16 ms
4,376 KB
testcase_17 AC 19 ms
4,380 KB
testcase_18 AC 11 ms
4,380 KB
testcase_19 AC 19 ms
4,380 KB
testcase_20 AC 20 ms
4,376 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
#define FOR(i,a,b) for(int i=(a);i<(b);i++)
#define FFOR(i,a,b) for(int i=(a);i<=(b);i++)
#define REP(i,b) FOR(i,0,b)
#define RREP(i,b) FFOR(i,1,b)
#define PB push_back
#define F first
#define S second
#define BE(c) c.begin(),c.end()
using namespace std;
typedef long long LL;
typedef int ut;
typedef long double ld;
typedef pair<ut,ut> pr;
typedef vector<pr> Vpr;
typedef vector<ut> VI;
typedef pair<ut,pr> ppr;
typedef vector<ppr> Vppr;
typedef priority_queue<pr,Vpr,greater<pr> > PQ;
typedef priority_queue<ppr,Vppr,greater<ppr> > PprQ;
const int SIZE=5+3*1e+5;
const ut INF=1<<30;
const ld eps=1e-6;
const LL p=7+1e+9;
int nums[SIZE];
int main(){
	string s;
	cin >> s;
	REP(i,s.size())
		nums[s[i]-'a']++;
	cout << min(min(nums['t'-'a'],nums['r'-'a']),nums['e'-'a']/2) << endl;
}
0