恒生电子笔试题3(7)
时间:2025-03-11
时间:2025-03-11
恒生电子笔试题
while (nCurPath >= 0) { // check if reach end position if (check_end(path[nCurPath].pCur)) { goto SavePath; } // find next neighbor, and continue the next turn search struct NODE* pNextNode = get_neighbor(node_examed, path[nCurPath]); if (pNextNode) { add_checked_neighbor(node_examed, pNextNode); path[nCurPath + 1].pCur = pNextNode; path[nCurPath + 1].pNext = NULL; nCurPath++; } else { nCurPath--; } } return 0;
SavePath: // save found path to "maze" return 1; }
上一篇:09级电信二班赵晓飞毕业论文