DEV Community

Discussion on: Code Golf Challenge: Palindrome Detector

Collapse
 
daveturissini profile image
David • Edited
let p = (w) => { let i = 0,c = w[i],l=w.length - 1;while(c){if(c !== w[l-i]){return false}c=w[++c]}return true}