結果
| 問題 | No.1070 Missing a space | 
| コンテスト | |
| ユーザー |  | 
| 提出日時 | 2020-06-08 06:54:25 | 
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) | 
| 結果 | 
                                AC
                                 
                             | 
| 実行時間 | 3 ms / 1,000 ms | 
| コード長 | 354 bytes | 
| コンパイル時間 | 651 ms | 
| コンパイル使用メモリ | 85,948 KB | 
| 最終ジャッジ日時 | 2025-01-11 00:06:42 | 
| ジャッジサーバーID (参考情報) | judge5 / judge3 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 7 | 
ソースコード
#include <iostream>
#include <vector>
#include <algorithm>
#include <queue>
#include <set>
#include <string>
#include <map>
#include <numeric>
using namespace std;
typedef long long int ll;
int main(){
	cin.tie(nullptr);
	ios::sync_with_stdio(false);
	string s; cin >> s;
	int n=s.size();
	for(char c:s){
		if(c=='0')n--;
	}
	n--;
	cout << n << endl;
}
            
            
            
        