Backtracking

All possible subsets of distinct integers
AskAI

This problem involves finding all possible subsets of distinct integers. The solution set must not contain duplicate subsets, and the elements in each subset must be in non-descending order.

Find all subsets of a set of distinct integers
AskAI

This problem asks to return all possible subsets of a given set of distinct integers. For example, for the input [1,2,3], the output would be all possible subsets of those integers: [1], [2], [3], [1,2], [1,3], [2,3], and [1,2,3].

String Permutations
AskAI

The problem is to find all possible permutations of a given string. For example, given the input string "abc", the output should be ["abc", "acb", "bac ", "bca", "cab", "cba"].

Find the Longest Path of Consecutive Integers in a 2D Array
AskAI

This problem is about finding the longest path of consecutive integers in a 2D array. The input is a 2D array of integers, and the output is the length of the longest path.

Validate Sudoku Board
AskAI

This function takes in a 2D array and determines if it is a valid Sudoku board. A Sudoku board is valid if each row, column, and 3x3 subarray contains exactly 9 integers.

2D Array - Longest Path of Consecutive Integers
AskAI

This is a backtracking problem where the goal is to find the longest path of consecutive integers in a 2D array, starting from the top left corner. The path can only move up, down, left, or right, and each cell can only be visited once.

Shortest Path in a 2D Array of Black and White Pixels
AskAI

This problem is about finding the shortest path in a 2D array of black and white pixels, from the top left corner to the bottom right corner, in which only black pixels are visited.

"Word Search in a 2D Grid"
AskAI

Given a 2D array of letters and a word, this function returns whether the word can be found in the array by reading sequentially adjacent letters. The same letter cell may not be used more than once.