title: error: cannot find symbol ...String base64 = Base64.encodeToString(array, Base64.DEFAULT);
body: <p>I am trying to run a java code <a href="https://www.tutorialspoint.com/compile_java_online.php" rel="nofollow noreferrer">here</a></p>
  <p>I have this line</p>
  <pre><code>String base64 = Base64.encodeToString(array, Base64.DEFAULT);
  </code></pre>
  <p>when I try to run the code I have this error, pointing to this line</p>
  <pre><code>$javac HelloWorld.java
  HelloWorld.java:56: error: cannot find symbol
      String base64 = Base64.encodeToString(array, Base64.DEFAULT);
                                                         ^
    symbol:   variable DEFAULT
    location: class Base64
  1 error
  </code></pre>
  <p>at the beginning of the code I am importing this:</p>
  <pre><code>import java.security.MessageDigest;
  import java.security.NoSuchAlgorithmException;
  import java.util.Base64;
  
  public class HelloWorld{
  
  ... bla bla bla
  </code></pre>
  <p>what should I import, so I can run this code?</p>