Mars Exploration

  • + 0 comments

    If you don't want to use zip:

    def marsExploration(s):
        return sum(s[i] != 'SOS'[i%3] for i in range(len(s)))