If we have to find out that path is exists then again we need two call if right return false we will checkout for the down part and vice-versa right??
Rat in Maze problems
yes
we will check both down and right path
@chhavibansal why we cann’t do like that here we have
bool rightSuccess = rec call
bool downSucces = rec call
// Backtrack from here
then checkout if one return true then return true else false
I am thinking like that
if rightSuccess return true we will return true and call the function in forward directions
else
if downSuccess return true then return true and call the rec fuctions in forward first
and after that backtrack
@Vikaspal
bro try to implement what u think in the code
if it works fine then well and good
nothing is wrong if it works
and there are multiple way sof doing the same thing
try implementing and then share code if u have some issues
Great @Vikaspal
that is what i was saying if u think of some method try implementing it
then if it comes wrong u can put a doubt on the portal