Amazon Interview Question: Given two words "CAT", "FAR" ... | Glassdoor

Interview Question

Software Developer, Video Interview Seattle, WA

Given two words "CAT", "FAR" determine if you can get from

  the first to the second via single transformations of valid words....e.g. 1 transformation gets you from CAT to CAR changing T to R, then another gets you from CAR to FAR changing the C to F...all are valid english words.

Interview Answer

1 Answer


This graph problem had to be actually coded on the white board. I used a BFS search, but the program was still pretty complex for a white board exercise.

Interview Candidate on Jul 2, 2011

Add Answers or Comments

To comment on this, Sign In or Sign Up.