結果
問題 |
No.671 1000000007
|
ユーザー |
![]() |
提出日時 | 2018-09-30 17:00:56 |
言語 | C (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 2,000 ms |
コード長 | 338 bytes |
コンパイル時間 | 136 ms |
コンパイル使用メモリ | 29,568 KB |
実行使用メモリ | 5,248 KB |
最終ジャッジ日時 | 2024-10-12 09:13:04 |
合計ジャッジ時間 | 706 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 9 |
ソースコード
#include <stdio.h> #include <stdlib.h> #include <string.h> int habs(int n){ return n < 0 ? -n : n; } int main(){ char N[20]; int n = 0; int i; scanf("%s", N); for(i = 0; i < strlen(N); i++){ if(N[i] == '0') n++; } printf("%d\n", habs(n - 8)); return 0; }