Execute a file with arguments in Python shell February 9, 2023 by Tarik Actually, wouldn’t we want to do this? import sys sys.argv = ['abc.py','arg1', 'arg2'] execfile('abc.py')