結果
問題 |
No.656 ゴルフ
|
ユーザー |
![]() |
提出日時 | 2018-06-04 16:21:16 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 310 bytes |
コンパイル時間 | 422 ms |
コンパイル使用メモリ | 55,724 KB |
実行使用メモリ | 6,948 KB |
最終ジャッジ日時 | 2024-06-30 09:41:20 |
合計ジャッジ時間 | 974 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | WA * 4 |
other | WA * 6 |
ソースコード
#include <cstdlib> #include <iostream> #include <typeinfo> using namespace std; int main(){ char s[1000]; cin>>s; int count =0; for(int i=0;i<1000;i++){ if(s[i]=='\0'){ cout<<"count:"<<count; break; } if(s[i]=='0'){ count+=10; }else{ count+=s[i]-48; } } }