calculating branch coverage