摘要:
题目描述 Suppose an array sorted in ascending order is rotated at some pivot unknown to you beforehand. (i.e., [0,1,2,4,5,6,7] might become [4,5,6,7,0,1,2 阅读全文
摘要:
Given an array of integers, find if the array contains any duplicates. Your function should return true if any value appears at least twice in the arr 阅读全文
摘要:
Given two strings s and t, determine if they are isomorphic. Two strings are isomorphic if the characters in s can be replaced to get t. All occurrenc 阅读全文
摘要:
Given a non-empty array of integers, every element appears twice except for one. Find that single one. Note: Your algorithm should have a linear runti 阅读全文
摘要:
Given an array of strings, group anagrams together. Example: All inputs will be in lowercase. The order of your output does not matter. 解法: 首先遍历输入,同时对 阅读全文
摘要:
LeetCode 1. Two Sum Given an array of integers, return indices of the two numbers such that they add up to a specific target. You may assume that each 阅读全文
摘要:
LeetCode 383. Ransom Note https://leetcode.com/problems/ransom-note/ 原题地址 题目描述 Given an arbitrary ransom note string and another string containing let 阅读全文