Question: Assuming I have this string:

```py
TEST = 'GAMES HELLO VAUXHALL RUNS=15 TESTED=3'

```

if the text `'RUNS='` exists in `TEST`, I want to extract the value `15` into a variable, nothing else from that string.

Answer: 
You can use `re` module:

```py
import re

s = "GAMES HELLO VAUXHALL RUNS=15 TESTED=3"

m = re.search(r"RUNS=(\d+)", s)
if m:
    print("RUN=... found! The value is", m.group(1))

```

Prints:

```none
RUN=... found! The value is 15

```
Just split the line and check if one of the items starts with your desired string:

```py
TEST = 'GAMES HELLO VAUXHALL RUNS=15 TESTED=3'

def extract(s: str):
    for i in s.split():
        if i.startswith("RUNS="):
            return int(i.split("=")[1])

print(extract(TEST))

```