I have automated to send the numbers from the numbers array one by one to text box as shown below, while the numbers are get it from the array and at the same time how to get the mail id randomly one by one from the email array?
import time
numbers = [2589001,2589002,2589003,2589004,2589005,2589006,2589007,2589008,2589009,2589010]
email = ["mail1@gmail.com","mail2@gmail.com","mail3@gmail.com","mail4@gmail.com","mail5@gmail.com"]
def oo() :
for idx in email :
email_from_list = email[idx%len(email)]
#I want to put those email function code here and need to pass this def oo()
c = 0
def vs () :
for idx, nm in enumerate(numbers) :
#Number Input
WebDriverWait(browser, 2500).until(EC.presence_of_element_located((By.NAME, "Number"))).send_keys(nw)
time.sleep(1)
WebDriverWait(browser, 2500).until(EC.presence_of_element_located((By.NAME, "Number"))).send_keys(oo()) #<---- here need to call
time.sleep(1)
#I need code here to get email id one by one randomly from array <--- Fix you wording. You don't actually want them one by one randomly
w = 0
while w < 50 :
vs ()
w += 1