原创 leetcode-3Sum clostest

Question: Given an array S of n integers, find three integers in S such that the sum is closest to a given number, targ

原创 leetcode-Minimum Absolute Difference in BST

Question: Given a binary search tree with non-negative values, find the minimum absolute difference between values of

原创 leetcode-Basic Calculator

Question: Implement a basic calculator to evaluate a simple expression string. The expression string may contain open (

原创 leetcode-Happy Number

Question: Write an algorithm to determine if a number is “happy”. A happy number is a number defined by the following p

原创 leetcode-Sort Characters By Frequency(基數排序實現)

Question: Given a string, sort it in decreasing order based on the frequency of characters. Example 1: Input: “tree” O