I'm programming in Perl...
Have quiz on a website, it's 20 question with three alternative and one elimination question. The answer on the elimation question is a value between 1 and 50.
The database who is connected to the website have the columns "name", "points" and "elimination"
I need a SQL-statment or a perl script to order the the competitor who have the same points. The one who is closest to the the elimination answer should be first.
E.g: Two competitor have 20 points, one of them have answered 15 an the other 25 on the elimination question. The correct answer is 17, so 15 is closest and he should be number one.
Anyone who can help me!
Have quiz on a website, it's 20 question with three alternative and one elimination question. The answer on the elimation question is a value between 1 and 50.
The database who is connected to the website have the columns "name", "points" and "elimination"
I need a SQL-statment or a perl script to order the the competitor who have the same points. The one who is closest to the the elimination answer should be first.
E.g: Two competitor have 20 points, one of them have answered 15 an the other 25 on the elimination question. The correct answer is 17, so 15 is closest and he should be number one.
Anyone who can help me!