def code_coverage
      indices = (0...@lines.size).select{|i| is_code? i }
      return 0 if indices.size == 0
      count = 0
      indices.each {|i| count += 1 if @coverage[i] }
      1.0 * count / indices.size
    end
def code_coverage
      indices = (0...@lines.size).select{|i| is_code? i }
      return 0 if indices.size == 0
      count = 0
      indices.each {|i| count += 1 if @coverage[i] }
      1.0 * count / indices.size
    end
Code coverage rate: fraction of lines of code executed, relative to the
 total amount of lines of code (loc). Returns a float from 0 to 1.0.