Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 5d30dfa

Browse files
authoredMay 28, 2022
Update 0005_Longest_Palindromic_Substring.java
1 parent b08f292 commit 5d30dfa

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

‎Java/0005_Longest_Palindromic_Substring.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ public String longestPalindrome(String s) {
2727
// from start and end elements, expand mirrored area
2828
private int expandCenter(String s, int start, int end) {
2929
while(start >= 0 && end < s.length()) {
30-
// if it is mirrored, start goes to left and, end goes to right side of string
30+
// if it is mirrored, the start goes to left and, the end goes to right side of string
3131
if(s.charAt(start) == s.charAt(end)) {
3232
start--;
3333
end++;

0 commit comments

Comments
 (0)
Please sign in to comment.