Skip to content

Commit 4cc479e

Browse files
authored
Create Avalon.md
1 parent 0614029 commit 4cc479e

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

2018.12.3-leetcode58/Avalon.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
class Solution {
2+
public int lengthOfLastWord(String s) {
3+
String[] sArr = s.trim().split(" ");
4+
if (sArr.length == 0)
5+
return 0;
6+
return sArr[sArr.length-1].length();
7+
}
8+
}

0 commit comments

Comments
 (0)