title: Slideshow not working :/
body: <pre><code>&lt;html&gt;
   &lt;head&gt;
   &lt;style&gt;
  .mySlides {
  display:none;
  height:200px;
  width:800px;
  margin-left:auto;
  margin-right:auto;
  }
  &lt;/style&gt;
   &lt;head&gt;
  &lt;body&gt;
  &lt;script&gt;
  
  var myIndex = 0;
  carousel();
  
  function carousel() {
      var i;
      var x = document.getElementsByClassName("mySlides");
      for (i = 0; i &lt; x.length; i++) {
          x[i].style.display = "none";
      }
      myIndex++;
      if (myIndex &gt; x.length) { myIndex = 1 }
      x[myIndex - 1].style.display = "block";
      setTimeout(carousel, 2000); // Change image every 2 seconds
      }
   &lt;/script&gt;
    &lt;section id="images"&gt;
                &lt;img id="yeah" class="mySlides" src="image1.jpg" /&gt;
                &lt;img class="mySlides" src="image2.jpg" /&gt;
                &lt;img class="mySlides" src="image3.jpg" /&gt;
            &lt;/section&gt;
  &lt;/body&gt;
  &lt;/html&gt;
  </code></pre>
  
  <p>So i'm not sure why this automatic slideshow isn't working when it was copied almost verbatim from w3schools, the result doesn't display anything. Ive been trying to find out whats wrong with it for about a day and a half now and still no luck, Please Help! </p>