x = list(input().split(',')) for i in x: if i != 'AC': print('Failed...') break else: print('Done!')