calculating finish level based on lines