title: Python error when pulling random URL from list
body: <p>I am new to python and still learning.</p>
  <p>I am just playing around with small scripts I am creating for fun to learn, here is what I got.</p>
  <pre><code>from selenium import webdriver
  import time
  import random
  
  driver = webdriver.Chrome(&quot;C:\\Users\\16239\\youtubebot\\chromedriver&quot;)
  
  
  videos = [
      &quot;https://www.youtube.com/watch?v=COAdbTDTDFc&quot;
      &quot;https://www.youtube.com/watch?v=p_2wemVUQnc&quot;
      &quot;https://www.youtube.com/watch?v=A8fODOFiBq0&quot;
      &quot;https://www.youtube.com/watch?v=tmgT01e1sGQ&quot;
      &quot;https://www.youtube.com/watch?v=_eqEuBp3jJw&quot;
      &quot;https://www.youtube.com/watch?v=09IRNL2TsHM&quot;
      &quot;https://www.youtube.com/watch?v=uUIugt-GsbY&quot;
      &quot;https://www.youtube.com/watch?v=HqlBwWX218s&quot;
      &quot;https://www.youtube.com/watch?v=DrKafd3U4TY&quot;
  ]
  
  random_video = random.randint(0,8)
  sleep_time = random.randint(60,120)
  
  for i in range(7000):
      print(&quot;Running the Video for {} time&quot;.format(i))
      driver.get(videos[random_video])
      time.sleep(sleep_time)
  
      driver.quit()
  </code></pre>
  <p>the issue is when I run it I am getting the error.</p>
  <pre><code>driver.get(videos[random_video])
  IndexError: list index out of range
  </code></pre>
  <p>I have 9 in the videos list and the random_video variable is calling 0 - 8 and I cant figure out the error. please help</p>