Closed chloeslam closed 3 years ago
Answering Chloe's 2nd question, please read #134 .
@Abner3 Thank you for your referral! I think [ship, sheep, she] is a valid return because the most recent picked candidate was "ship", then the second most recently picked candidate was "sheep", and "she" the word that I chose to make the trie return first that was not recently picked
@chloeslam I realized my question is incomplete and confusing since there are two versions of getCandidates we can implement (regular versus extra credit implementation). I edited out the question since the updated HW2 page clarifies my initial question.
@Abner3 Sounds good. Yeah, I was going to comment question 3 out because the HW2 clarifies it too. Thank you!
If getCandidates() has the input prefix of "sh" and "sh" exists in the trie, should getCandidates() return "sh" as a candidate?
~Yes.~
Question 1: To assess our algorithm speed, will our program speed be compared to our classmates? (similar to how it was assessed for HW1?)
I have not received the rubrics at this moment. But I guess it could be highly likely that way.
@lujiaying Thank you for your clarification! A question about your first answer though, I thought "sh" would not be returned since issue #134 was discussed that "sh" would not be returned?
Thank you for your clarification! A question about your first answer though, I thought "sh" would not be returned since issue #134 was discussed that "sh" would not be returned?
In #134, "sh" not given in dictionary.txt, thus not exist in Trie tree.
In your case, you said "sh" is in Trie Tree. So following your assumption, the output is totally determined by the given dictionary.txt.
@lujiaying That makes sense. I appreciate your help so much, thank you!
Thank you for your clarification! A question about your first answer though, I thought "sh" would not be returned since issue #134 was discussed that "sh" would not be returned?
In #134, "sh" not given in dictionary.txt, thus not exist in Trie tree.
In your case, you said "sh" is in Trie Tree. So following your assumption, the output is totally determined by the given dictionary.txt.
I am looking at dict.txt and it has "sh" in it. https://raw.githubusercontent.com/emory-courses/dsa-java/master/src/main/resources/dict.txt
Thank you for your clarification! A question about your first answer though, I thought "sh" would not be returned since issue #134 was discussed that "sh" would not be returned?
In #134, "sh" not given in dictionary.txt, thus not exist in Trie tree. In your case, you said "sh" is in Trie Tree. So following your assumption, the output is totally determined by the given dictionary.txt.
I am looking at dict.txt and it has "sh" in it. https://raw.githubusercontent.com/emory-courses/dsa-java/master/src/main/resources/dict.txt
Oh that is a good point. I need to ask Dr. Choi's opinion to see what is the expected output.
Please temporarily follow the case/convention in Textbook (not output the word itself)
From Dr. Choi's comment:
those test cases as well as examples are dummies, not meant to be what's supposed to be implemented
That means if "sh" exists in dictonary.txt, please return it as well.
@lujiaying Thank you!
Question 1: To assess our algorithm speed, will our program speed be compared to our classmates? (similar to how it was assessed for HW1?)
Question 2: If getCandidates() has the input prefix of "sh" and "sh" exists in the trie, should getCandidates() return "sh" as a candidate?