def main(): from sys import stdin readline = stdin.readline s = readline()[:-1] n = len(s) t = 'kadomatsu' if n > len(t): print('No') exit() arr_t = [x for x in t] delta = [] for i in range(n): if s[i] in arr_t: delta.append(arr_t.index(s[i])) arr_t.remove(s[i]) flag = (delta == list(sorted(delta))) print('Yes' if flag else 'No') if __name__ == "__main__": import sys readline = sys.stdin.readline def error(*args, end='\n'): print(*args, end=end, file=sys.stderr) main()