Correcting kjptheking so that it uses and array instead of a switch