We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
functionprocessData(input){//Enter your code hereinput=input.split('\n')varn=input[0];for(varz=1;z<=n;z++){vars=input[z].split('');varr=input[z].split('').reverse();varj=1;vari=1;while(j<=s.length-1){if(Math.abs(s[j].charCodeAt()-s[j-1].charCodeAt())==Math.abs(r[j].charCodeAt()-r[j-1].charCodeAt())){i++;}j++;}if(i==s.length){console.log('Funny')}else{console.log('Not Funny')}}}
Funny String
You are viewing a single comment's thread. Return to all comments →
hi @jcasarrubias i resolve in this way. good luck