mirror of
https://github.com/10h30/odin-javascript-exercises.git
synced 2026-06-05 15:09:09 +09:00
Use const for palindrome solution variable (#439)
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
const palindromes = function (string) {
|
||||
// Since we only consider letters and numbers, create a variable containing all valid characters
|
||||
let alphanumerical = 'abcdefghijklmnopqrstuvwxyz0123456789';
|
||||
const alphanumerical = 'abcdefghijklmnopqrstuvwxyz0123456789';
|
||||
|
||||
// Convert to lowercase, split to array of individual characters, filter only valid characters, then rejoin as new string
|
||||
const cleanedString = string
|
||||
|
||||
Reference in New Issue
Block a user