原文:【LeetCode】162. Find Peak Element (3 solutions)

Find Peak Element A peak element is an element that is greater than its neighbors. Given an input array wherenum i num i , find a peak element and return its index. You may imagine thatnum num n . For ...

2014-12-05 23:16 0 4529 推薦指數:

查看詳情

[LintCode] Find Peak Element II

There is an integer matrix which has the following features: The numbers in adjacent positions a ...

Sun May 17 21:03:00 CST 2015 3 2283
LeetCode】14. Longest Common Prefix (2 solutions)

Longest Common Prefix Write a function to find the longest common prefix string amongst an array of strings. 解法一: 思路:設置一個位數記錄器num,遍歷所有字符串的第num位 ...

Tue Nov 04 20:46:00 CST 2014 0 2323
 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM