Iremia's blog

By Iremia, history, 4 years ago, In English
  • Vote: I like it
  • 0
  • Vote: I do not like it

»
4 years ago, # |
  Vote: I like it +10 Vote: I do not like it

Make sure you set each node as visited when you push it into the queue, not when you pop it from the queue. Otherwise, you could push the same node to the queue multiple times. Here is a link to my accepted submission: 99284568