JSFiddle - React, Tailwind, and code Playground

by Jithin Raj P R

JavaScript

var isPalindrome = function(x) {
    console.log(String(x).split(''));
    const val = String(x).split('').join('');
    const reValue = val.reverse().join('');
    console.log(val === reValue)
};

isPalindrome(102);