I have a string like this
>>> x=\"Alpha_beta_Gamma\" >>> words = [y for y in x.split(\'_\')] >>> words [\'Alpha\', \'beta\', \'Gam
words = x.split("_") for word in words: if word[0] == word[0].upper() and word[1:] == word[1:].lower(): print word, "is conformant" else: print word, "is non conformant"