How to Implement Default Class in Java


In this example we will show how to implement default class in Java.

Source Code

package com.beginner.examples;

class Default {
  public static void main(String[] args) {
    System.out.println("Hello World!");// Hello World!
  }
}

Output:

Hello World!
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments