JSFiddle - React, Tailwind, and code Playground

by Fabian Allel

JavaScript

String.prototype.esPar=function(){
    return (this%2)==0? true: false; 
};



console.log("2".esPar());
console.log("2".toString());

String.prototype.esImpar=function(){
    return (this%2)==0? false: true; 
};
console.log("2".esImpar());
console.log("2".toString());