We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d76ef6b commit b5edb76Copy full SHA for b5edb76
125/solution.js
@@ -3,7 +3,7 @@
3
* @return {boolean}
4
*/
5
const isPalindrome = (s) => {
6
- s = s.replace(/[^a-zA-Z0-9]+/g, '').trim().toLowerCase();
+ s = s.replace(/[^a-zA-Z0-9]+/g, '').toLowerCase();
7
let l = 0, r = s.length - 1;
8
9
while (l <= r) {
0 commit comments