Currently I have a script that finds all the lines across multiple input files that have something in the format of 
`Matches: 500 (54.3 %)` and prints out the top 10 highest matches in percentage.

I want to be able to have it *also* output the top 10 lines for score ex: Score: 4000

```
import re

def get_values_from_file(filename):
    f = open(filename)
    winpat = re.compile("([\d\.]+)\%")
    xinpat = re.compile("[\d]") #ISSUE, is this the right regex for it? Score: 500****

    values = []
    scores = []

    for line in f.readlines():
        if line.find("Matches") >=0:
        percn = float(winpat.findall(line)[0])
        values.append(percn)

    elif line.find("Score") >=0:
        hey = float(xinpat.findall(line)[0])
        scores.append(hey)
    return (scores,values)

all_values = []    
all_scores = []

for filename in ["out0.txt", "out1.txt"]:#and so on
values = get_values_from_file(filename)
all_values += values
all_scores += scores

all_values.sort()
all_values.reverse()

all_scores.sort()  #also for scores
all_scores.reverse()

print(all_values[0:10])
print(all_scores[0:10])

```

Is my **regex for the score format correct?** I believe that's where I am having the issue, as it doesn't output both correctly.

Any thoughts? Should I split it into two functions?

Thank you.