Last active
October 8, 2017 00:03
-
-
Save mizushou/59144d44c60eb048d49e58a49ff08655 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.io.BufferedReader; | |
import java.io.InputStreamReader; | |
class Main { | |
public static void main(String[] args) throws Exception { | |
BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); | |
String l = br.readLine(); | |
int c = 0; | |
for(int i = 0; i < 6; i++) { | |
if(l.charAt(i) == '1') { | |
c++; | |
} | |
} | |
System.out.println(c); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Tenka1 Programmer Beginner Contest