Category: python
Consider the following function to make changes to an array of numbers: func modify(arr, op, idx) { // add by 1 index idx if (op == 0) { arr …
Return all non-negative integers of length N such that the absolute difference between every two consecutive digits is K. Note that every number in the answer must not have …
Given two integers n and k, return all possible combinations of k numbers out of 1 … n. Example: Input: n = 4, k = 2 Output: , , …
Given a column title as appear in an Excel sheet, return its corresponding column number. For example: A -> 1 B -> 2 C -> 3 ... Z -> …
Given an array of integers, 1 ≤ a ≤ n (n = size of array), some elements appear twice and others appear once. Find all the elements that appear …