I'm creating a program in Python and I have a problem with a for loop and opening program in this loop. The program is supposed to run e.g. 5 times and it only runs once
import subprocess
z = int(input())
def run():
subprocess.run('notepad.exe')
a = 0
while(a<z):
a = a + 1
run()
I've tried creating a function and replacing the for loop with a while loop but it doesn't work. Sorry for my English