@adnen/ispalaindrom
v1.0.3
Published
isPalaindrom algoritme , just checking to the middel of the string
Downloads
7
Maintainers
Readme
isPalaindrom solution (checking to the middel of the string)
install
npm install @adnen/ispalaindrom
Test
npm run test
Usage
// TYPESCRIPT FILE
import isPalindrome from "@adnen/ispalaindrom";
const str : string = "racecar";
const result = isPalindrome(str);
console.log(result);
// true
const strs : sring[] = ['redivider', 'deified', 'civic', 'radar', 'level', 'rotor', 'kayak', 'reviver', 'racecar', 'madam','','a'];
const checkAll = strs.map(isPlindrom);
console.log(checkAll)
// [true,true,true,true,true,true,true,true,true,true,true,true]