結果
| 問題 | No.289 数字を全て足そう | 
| コンテスト | |
| ユーザー |  btk | 
| 提出日時 | 2015-10-16 22:25:28 | 
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 2 ms / 1,000 ms | 
| コード長 | 232 bytes | 
| コンパイル時間 | 566 ms | 
| コンパイル使用メモリ | 56,308 KB | 
| 実行使用メモリ | 5,248 KB | 
| 最終ジャッジ日時 | 2024-10-07 20:05:20 | 
| 合計ジャッジ時間 | 1,316 ms | 
| ジャッジサーバーID (参考情報) | judge4 / judge2 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 21 | 
ソースコード
#include <iostream>
#include <string>
using namespace std;
int main() {
    string str;
    cin>>str;
    int res=0;
    for(auto& c : str){
        if(c>='0'&&c<='9')
        res+=c-'0';
    }
    cout<<res<<endl;
    return 0;
}
            
            
            
        