Hey,i wrote the code following above algorithm,the code is getting many compilation errors.Pleaee correct the code and tell me my errors.I have been trying since long

Link:https://ide.codingblocks.com/s/337307

This is done using DFS

hello @KetanPandey

image

here it should be bool in place of list< T >

Thank you for this mbut the code is still not printing required output,please help me and tell me my error

Its giving right answer in coding blocks IDE but not in any other id,Please check and make it compatible for all other IDE.Thanks

code logic has nothing to do with ide.
if it is working in one ide and not working in other ide then the problem is with ide only.
so check ur ide once

I have checked in many IDEs,its working in some and not working in several others IDEs.What might be the reason ,can you tell me more about ir

try updating ur ide, may be due to outdated c++ version(should be atleast 14+ ) it is not working

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.