def parse_ranges(ranges):
    """Helper function to parse coverage data ranges."""
    total_length = 0

    for single_range in ranges:
        (start, end) = single_range.values()
        length = end - start
        total_length = total_length + length

    return total_length