first version of score calculation