code: function applyRecords(path, records) {
    let numApply = 0;
    let maxSpecificity = 0;
  
    for (let i = 0; i < records.length; i = i + 1) {
      const record = records[i];
      if (record.path.test(path)) {
        numApply = numApply + 1;
        if (record.specificity > maxSpecificity) {
          maxSpecificity = record.specificity;
        }
      }
    }
  
    return {
      numApply,
      maxSpecificity
    }
  }
docs: /*
  Calculates the number of records that apply for the
  given path and the maximum specificity of all
  the records which apply.