THE WORLD'S LARGEST WEB DEVELOPER SITE

Java package Keyword

❮ Java Keywords


MyPackageClass.java

package mypack;

class MyPackageClass {
  public static void main(String[] args) {
    System.out.println("This is my package!");
  }
}

Run example »


Definition and Usage

The package keyword creates a package.


Related Pages

Read more about packages in our Java Packages Tutorial.


❮ Java Keywords