In Mini Program, how does JS take the module after hashing a string?

I want to implement the need to enter a name to get a random answer, but enter the same name to get the same answer.
read the post and said I wanted to hash the number, and now I have transcoded the name entered by the user into five digits. Next, how to hash it and get a fixed random number in a specified range?

onLoad: function (options) {

this.data.name = wx.getStorageSync("name");
this.setData({
  name: this.data.name
});

this.setData({
  words: this.data.name.charCodeAt(0)
});
Jul.11,2021


Math.seed = this.data.words;
Math.seededRandom = function(max, min) {
  max = max || 0;
  min = min || 10;
  Math.seed = (Math.seed * 9301 + 49297) % 233280;
  var rnd = Math.seed / 233280.0;
  return min + rnd * (max - min);
};
for (var i = 0; i < 10; iPP) {
  console.log(Math.seededRandom());
}
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1eb3e49-2487.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1eb3e49-2487.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?