Given two arrays of strings, startWords and targetWords, determine how many strings in targetWords can be formed by appending a letter to any string in startWords and rearranging the letters.
Alice and Bob are opponents in an archery competition. Alice first shoots numArrows arrows, followed by Bob, in the target scoring sections from 0 to 11. The goal is to maximize Bob’s total score, ensuring that the sum of arrows shot by Bob equals numArrows.
You are given two integers, start and goal. The task is to determine the minimum number of bit flips required to convert start into goal. A bit flip consists of choosing a bit in the binary representation of a number and flipping it from 0 to 1 or from 1 to 0.
You are given an array of positive integers candidates. Your task is to evaluate the bitwise AND of every possible combination of numbers in the array and return the size of the largest combination where the result of the AND operation is greater than 0. Each number in the array may only be used once in each combination.
You are given an integer array cookies, where each element represents the number of cookies in a particular bag. You are also given an integer k, which denotes the number of children to distribute these bags of cookies to. Each bag must go to exactly one child, and cookies cannot be split between children. The unfairness of a distribution is defined as the maximum number of cookies any single child receives. Your goal is to return the minimum unfairness across all possible distributions.
You are given an integer array nums. In each operation, select a non-negative integer x and an index i, then update nums[i] to be equal to nums[i] AND (nums[i] XOR x). The task is to find the maximum possible bitwise XOR of all elements after applying the operation any number of times.