import random import os profile_file = ['Profile 20', 'Profile 25'] p = random.choice(profile_file) os.system('python yt_comment.py get --profile="'+p+'"')