Category: algorithms
You are given two strings s and t which both have length n. You can pick one character in s and another in t and swap them. Given you …
Given a list of integers nums, return whether you can partition the list into two non-empty sublists such that every number in the left sublist is strictly less than …
Given a binary tree root, return whether for every node in the tree other than leaves, its value is equal to the sum of its left child’s value and …
Given an integer n greater than 1, find all of its prime factors and return them in sorted order. You can write out a number as a product of …
You are given a two-dimensional list of integers tasks. Each element contains which represents a CPU task with id id, queued at time queue_time, that will run for duration …