摘要:
class Solution { public boolean validPalindrome(String s) { char ch[] = s.toCharArray(); int l = 0, r = ch.length - 1; while(l < r) { if(ch[l] == ch[r 阅读全文
posted @ 2022-03-06 17:33
北方寒士
阅读(56)
评论(0)
推荐(0)
摘要:
public ListNode reverseList(ListNode head) { if(head==null || head.next ==null){ return head; } ListNode cur = head.next; head.next = null; while(cur! 阅读全文
posted @ 2022-03-06 13:47
北方寒士
阅读(34)
评论(0)
推荐(0)
摘要:
给定一个字符串,验证它是否是回文串,只考虑字母和数字字符,可以忽略字母的大小写。 public boolean isPalindrome(String s) { int n = s.length(); int left = 0, right = n - 1; while (left < right) 阅读全文
posted @ 2022-03-06 13:20
北方寒士
阅读(28)
评论(0)
推荐(0)
该文被密码保护。 阅读全文
posted @ 2022-03-06 12:42
北方寒士
阅读(1)
评论(0)
推荐(0)

浙公网安备 33010602011771号