Bfs and dfs problems

can anyone suggest me good problems for bfs and dfs

Here is a nice one:- CodeChef: Practical coding for everyone

There is one very nice noble problem on bfs present on Hackerearth…I forgot its name, but it was like, given a Jee exam, with “N” questions in exam, +a for correct answer to each question, and -b for each incorrect answer, 0<=a,b<=20… How many different scores are possible ? Such a beautiful problem. Gives TLE by brute-force :slight_smile:

1 Like

Search dfs /bfs problems you will get lots of problems.

cp-algorithms.com contains some nice starting problems

1 Like