Which of the following websites has been used for similar fun tests? there are a lot of websites on the Internet, similar to fortune-telling? let's see if you enter the same person name in your next life and the results are the same. I want to do it, but I don't know the data structure, how to design the program, how to input the same words, and the results must be the same. I wanted to create a list, but it was a big headache to think about this record table! Which of the following websites has been tested?
There are a lot of online, similar to what fortune teller, look at your next life or something
That is, input the same person name and the results are the same,
I want to do it, but I don't know the data structure and how to design the program,
Enter the same word and the output result must be the same,
I wanted to create a list, but it was a big headache to think about this record table!
Share:
------ Solution --------------------
Pseudoscience!
All output results are randomly generated.
The pseudo-random number generator rand can seeding seeds. the same seeds will generate the same pseudo-random number sequence.
Therefore, you only need to use the input data as the seed.
Srand (hexdec (md5 ($ input, 1 )));