結果
| 問題 | 
                            No.279 木の数え上げ
                             | 
                    
| コンテスト | |
| ユーザー | 
                             | 
                    
| 提出日時 | 2017-08-27 23:16:21 | 
| 言語 | C++14  (gcc 13.3.0 + boost 1.87.0)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 318 bytes | 
| コンパイル時間 | 508 ms | 
| コンパイル使用メモリ | 66,052 KB | 
| 実行使用メモリ | 6,824 KB | 
| 最終ジャッジ日時 | 2024-11-06 07:03:44 | 
| 合計ジャッジ時間 | 1,562 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge5 / judge3 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| other | WA * 21 | 
ソースコード
#include <iostream>
#include <string>
using namespace std;
using ll = long long;
int main()
{
string s;
cin >> s;
ll numt =0;
ll numr = 0;
ll nume = 0;
for(const char c : s){
if(c == 't'){
numt++;
} else if (c == 'r'){
numr++;
} else if (c == 'e'){
nume++;
}
}
cout << numt*numr*(nume*(nume-1))/2 << endl;
return 0;
}