Create a list from variables located in script lines x-y

Hi. Imagine that I have some variables stored in a Python script which are located in the lines 3 to 5, both inclusive. I want to create a list that contains these variables. Is there any function to read from the very script I’m writing and append the content of these variables into a new list?

This is an example of what I want:

#1 #This is a script that contains data about my new car.
#3 vehicle_type = “car”
#4 vehicle_model = “ferrari”
#5 vehicle_license_plate = “2851GHT”
#7 new_list = [#empty]
#8 #Some formula to store those variables directly read from the script into a new list
#9 new_list = [“car”, “ferrari”, “2851GHT”]
#10 #End of the script

If you just want to put those variables as a list, you could do
new_list = [vehicle_type, vehicle_model, vehicle_license_plate]

If you want to add stuff to an existing list instead, you can use .append

list1 = ['a', 'b', 'c']
# list1 is now ['a', 'b', 'c', 'd']

That of course is one solution. But what I specifically want is that those variables are read from a piece of my script (lets say lines 3 to 5 inclusive) and put into a Numpy array. This is to simplify, as with three variables it is no headache to write them one by one as in your example (new_list = [vehicle_type, vehicle_model, vehicle_license_plate]), but with one hundred stored variables (for example) I would need something faster.