Tag: python
Given an array of integers A, return the largest integer that only occurs once. If no integer occurs once, return -1. Example 1: Input: Output: 8 Explanation: The maximum …
There is a special keyboard with all keys in a single row. Given a string keyboard of length 26 indicating the layout of the keyboard (indexed from 0 to …
The k-digit number N is an Armstrong number if and only if the k-th power of each digit sums to N. Given a positive integer N, return true if …
You are given coins of different denominations and a total amount of money. Write a function to compute the number of combinations that make up that amount. You may …
Given n processes, each process has a unique PID (process id) and its PPID (parent process id). Each process only has one parent process, but may have one or …