import java.io.*;
import java.util.*;
public class Main {
public static void main(String[] args) throws Exception {
BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
BufferedWriter bw = new BufferedWriter(new OutputStreamWriter(System.out));
StringTokenizer st = new StringTokenizer(br.readLine());
bw.write(Integer.toString(st.countTokens()));
bw.flush();
br.close();
bw.close();
}
}
StringTokenizer 메소드 countTokens()
를 사용하면 되는 간단한 문제였다.