title: First HelloWorld servlet with java.lang.ClassNotFoundException
body: <p>After doing all tutorial step by step, my first HelloWorld doesn't work like in tutorial. I have this error:</p>
  
  <blockquote>
    <p>java.lang.ClassNotFoundException: pl.random.servlets.HelloWorldServlet</p>
  </blockquote>
  
  <p>My files:  </p>
  
  <p>web.xml:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" id="WebApp_ID" version="3.0"&gt;
   &lt;servlet&gt;
      &lt;servlet-name&gt;HelloWorld&lt;/servlet-name&gt;
      &lt;servlet-class&gt;pl.random.servlets.HelloWorldServlet&lt;/servlet-class&gt;
    &lt;/servlet&gt;
    &lt;servlet-mapping&gt;
      &lt;servlet-name&gt;HelloWorld&lt;/servlet-name&gt;
      &lt;url-pattern&gt;/test&lt;/url-pattern&gt;
    &lt;/servlet-mapping&gt;
  &lt;/web-app&gt;
  </code></pre>
  
  <p>HelloWorldServlet.java</p>
  
  <pre><code>package pl.random.servlets;
  
  import java.io.PrintWriter;
  import java.io.IOException;
  
  import javax.servlet.ServletException;
  import javax.servlet.http.HttpServlet;
  import javax.servlet.http.HttpServletRequest;
  import javax.servlet.http.HttpServletResponse;
  
  public class HelloWorldServlet extends HttpServlet{
  
      public static final long serialVersionUID = 102831973239L;
  
      public void doGet(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException {
          PrintWriter out = response.getWriter();
          out.print("Hello World");
  
  }}
  </code></pre>
  
  <p>and here my project explorer:</p>
  
  <p><a href="https://i.stack.imgur.com/HRv5a.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/HRv5a.png" alt="descriptionImage"></a></p>