input: Write a function to count the number of words in a given string. If the given string is empty then return 0.
  assert word_count('Hello world, this is a sentence.')==5
  assert word_count('')==0
  assert word_count('One more sentence')==3
  assert word_count('This  sentence   has extra   spaces')==5
  assert word_count('Single')==1
output: def word_count(s):
      if not s:
          return 0
      return len(s.split())