Skip to content

Latest commit

 

History

History
19 lines (10 loc) · 239 Bytes

File metadata and controls

19 lines (10 loc) · 239 Bytes

Problem 14: Longest Common Prefix

Difficulty: Easy

Problem

Write a function to find the longest common prefix string amongst an array of strings.

Example

strs = {"abc", "absedf", "abef"}

Returns "ab"