You have a lot of data in your class that looks like 'name' (at the moment you're using a variable num1, num2 etc for the name) and each 'name' maps to a 'value' (at the moment your values look like "Text 1", "Text 2" etc.
You might find it easier to use a dictionary for this data, rather than trying to define each name:value as a separate variable = value.
For example, you'd end up with something more like:
class Variables(object):
numbers = {
"num1": "Text 1",
"num2": "Text 2",
"num3": "Text 3",
}
Now it becomes much more straightforward to procedurally generate (a fancy way of saying automatically) that dictionary:
class Variables(object):
numbers = {
"num{}".format(i): "Text {}".format(i)
for i in range(100)
}
Now if you want them to be random numbers:
import random
class Variables(object):
numbers = {
"num{}".format(i): "Text {}".format(random.randrange(100))
for i in range(100)
}
v = Variables()
print v.numbers["num50"]