단어의 개수
s = input() cnt = 0 for i in s.split(): cnt = cnt + 1 print(cnt)
까다로운 문제라서 다른사람의 풀이를 참고했다.
https://wook-2124.tistory.com/257