How to generate an admission ticket online based on the existing user registration information in the database table and create an admission ticket for each user (especially the admission ticket number and test location, could you please give me some advice?
Reply to discussion (solution)
The admission ticket number is not generated and saved online.
Generally, candidates from the same location should be evenly assigned to each test site. candidates from the same location are not adjacent to each test site.
The admission ticket number is not generated and saved online.
Generally, candidates from the same location should be evenly assigned to each test site. candidates from the same location are not adjacent to each test site.
Well, it makes sense, but how can this problem be solved?
The basic algorithm is roughly as follows:
The number of test sites is known, and the number is sequential. candidates are sorted by source.
Traverse candidates and assign test sites. For each assignment, the test site number is plus one (cyclic count)
Repeat the above process for each test site to allocate seats
Okay, solved.