Update ida.cpp

Fixed problem pass in, fixed dfs return values