/* package whatever; // don't place package name! */
import java.util.*;
import java.lang.*;
import java.io.*;
/* Name of the class has to be "Main" only if the class is public. */
class Ideone
{
{function hasher(hashedValue)
{
var hash = 7;
var letters = "1c1707e8a20719056bfc9a232527c5bd";
for(var i = 0; i < hashedValue.length; i++)
{
hash = (hash * 23 + letters.indexOf(hashedValue[i]))
}
return hash;
}
function unhasher(hashNbr) {
var strpos = [];
var rst = 0;
var result = [];
var hash = hashNbr;
var letters = 'atdebilaeokrotum';
for( i = 10; i > 0; i-- ){
rst = ( hash % 23 );
strpos[i] = rst;
hash = (hash - rst)/23;
result[i-1]= letters.charAt(strpos[i]);
}
return result.join(''); // array of chars to string
}
// your code goes here
}
}