結果
問題 |
No.289 数字を全て足そう
|
ユーザー |
![]() |
提出日時 | 2019-02-24 21:39:55 |
言語 | C++17(clang) (17.0.6 + boost 1.87.0) |
結果 |
RE
|
実行時間 | - |
コード長 | 233 bytes |
コンパイル時間 | 567 ms |
コンパイル使用メモリ | 118,912 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-11-30 13:37:34 |
合計ジャッジ時間 | 3,845 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | WA * 1 RE * 2 |
other | WA * 1 RE * 20 |
ソースコード
#include <iostream> #include <vector> #include <string> using namespace std; int main() { int sum = 0; string s; cin >> s; for (int i = 0; i < (int)s.size(); i++) { if ('0' <= s[i] || s[i] <= '9') sum += stoi(&s[i]); } }