I_am_a_failure's blog

By I_am_a_failure, history, 23 months ago, In English
  • Vote: I like it
  • -6
  • Vote: I do not like it

23 months ago, # |
  Vote: I like it 0 Vote: I do not like it

My code https://ideone.com/QSR6CH . It is a simple bfs but you want to have lenght divides by 3. I have vertices v,state (for my code it is 3*v+state vertice) i search shortest path from s to v which whave the same remainder as state.