Compare commits
No commits in common. "ac72c9bbaaf4edf9983dbe5b70d7ceb1b9c40332" and "8f15fee32e75695e06c86535b6edbc7043a1d101" have entirely different histories.
ac72c9bbaa
...
8f15fee32e
|
|
@ -98,6 +98,16 @@ public class Solution {
|
||||||
System.out.println(result);
|
System.out.println(result);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
|
public static int removeElement(int[] nums, int val) {
|
||||||
|
for (int i = 0; i < nums.length; i++) {
|
||||||
|
if (val == nums[i]){
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return nums.length;
|
||||||
|
}
|
||||||
|
=======
|
||||||
// public static String longestCommonPrefix(String[] strs) {
|
// public static String longestCommonPrefix(String[] strs) {
|
||||||
// int index = 0;
|
// int index = 0;
|
||||||
// StringBuilder temp = new StringBuilder();
|
// StringBuilder temp = new StringBuilder();
|
||||||
|
|
@ -148,4 +158,6 @@ public class Solution {
|
||||||
}
|
}
|
||||||
return strs[0];
|
return strs[0];
|
||||||
}
|
}
|
||||||
|
|
||||||
|
>>>>>>> a83429a6b794491f269fccaa74b710ca4abc514b
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -19,6 +19,7 @@ public class test {
|
||||||
// Solution.merge(nums1,m,nums2,n);
|
// Solution.merge(nums1,m,nums2,n);
|
||||||
// String[] strs = new String[]{"flower","flow","flight"};
|
// String[] strs = new String[]{"flower","flow","flight"};
|
||||||
String[] strs = new String[]{"flower","flower","flower","flower"};
|
String[] strs = new String[]{"flower","flower","flower","flower"};
|
||||||
|
|
||||||
String result = Solution.longestCommonPrefix(strs);
|
String result = Solution.longestCommonPrefix(strs);
|
||||||
System.out.println(result);
|
System.out.println(result);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue