Update cookie_single.js

Added a function that return the index of the achievement score of a user.