題目: Implement a first in first out (FIFO) queue using only two stacks. The impl...
題目: Given an integer n, return true if it is a power of two. Otherwise, return...
題目: You are given a sorted unique integer array nums. A range [a,b] is the se...
題目: Given the root of a binary tree, invert the tree, and return its root. 給定一...
題目: Implement a last-in-first-out (LIFO) stack using only two queues. The imple...
題目: Given an integer array nums and an integer k, return true if there are two...
題目: Given an integer array nums, return true if any value appears at least twic...
題目: Given the head of a singly linked list, reverse the list, and return the re...
題目: Given two strings s and t, determine if they are isomorphic. Two strings...
題目: Given the head of a linked list and an integer val, remove all the nodes of...
題目: Write an algorithm to determine if a number n is happy. A happy number is...
題目: Write a function that takes an unsigned integer and returns the number of '...
題目: Reverse bits of a given 32 bits unsigned integer. 給定32位的unsigned integer,回...
題目: Given a string columnTitle that represents the column title as appears in a...
題目: Given an array nums of size n, return the majority element. The majority...
題目: Given an integer columnNumber, return its corresponding column title as it...
題目: Given the heads of two singly linked-lists headA and headB, return the node...
題目: Design a stack that supports push, pop, top, and retrieving the minimum ele...
題目: Given the root of a binary tree, return the postorder traversal of its node...
題目: Given the root of a binary tree, return the preorder traversal of its nodes...
題目: Given head, the head of a linked list, determine if the linked list has a c...
題目: Given a non-empty array of integers nums, every element appears twice excep...
題目: A phrase is a palindrome if, after converting all uppercase letters into lo...
題目: You are given an array prices where prices[i] is the price of a given stock...
題目: Given an integer rowIndex, return the rowIndexth (0-indexed) row of the Pas...
題目: Given an integer numRows, return the first numRows of Pascal's triangle....
題目: Given the root of a binary tree and an integer targetSum, return true if th...
題目: Given a binary tree, find its minimum depth. The minimum depth is the num...
題目: Given a binary tree, determine if it is height-balanced. 給定一個binary tree,判...
題目: Given an integer array nums where the elements are sorted in ascending orde...