added priority to headRules: rules, which are added earlier to headRules are favored over later while calculating the head