add two new functions:group and sqrt the score