Which of the following is an example of a problem that can be solved using backtracking?निम्नलिखित में से कौन एक समस्या का एक उदाहरण है जिसे बैकट्रैकिंग का उपयोग करके हल किया जा सकता है?
Show answerHide answer
Correct answer: (C) Solving the Sudoku puzzleसुडोकू पहेली को हल करना
Explanation
Sudoku is solved by backtracking. You place a digit, check the constraints, and undo the choice (backtrack) when no valid digit fits later. Factorial, finding the maximum and quicksort do not need trial and undo.Sudoku backtracking से हल होता है। आप एक अंक रखते हैं, constraints जाँचते हैं, और जब बाद में कोई वैध अंक न बैठे तो चुनाव को पलट देते हैं (backtrack)। Factorial, अधिकतम निकालना और quicksort में आज़माने और पलटने की ज़रूरत नहीं होती।