pseudo:
variable n is equal to 1
loop: if the last member registered to the site has not added karma...
for the member with the id equal to 'n', increase their karma by x. increase n by one.
else "Karma added." ; break;
end loop;
that seems really easy. i just dont know how to access the sql thru php.