A logic teacher invited her three star, equally talented, students into a room for a test. The following words are written on a chalkboard: cat, dog, has, max, dim, tag. She tells the students that she has picked one of the words on the board as a secret word, and is going to give each of them a piece of paper with a different letter from the secret word. No student can see the other students' papers.
After handing out the three sheets of paper, she tells the students that if anyone knows the secret word, they should write it on their sheet of paper and bring it to her. One student does so and the teacher says that he has the right answer. The other two students ponder a bit, then another writes a word and takes it to the teacher, who announces that that student is also correct. Finally, after some more thought, the third student correctly writes down the secret word.
What is the secret word?