If i run this code below in Netbeans
import java.io.Console;
public class Introduction {        
    public static void main(String[] args) {
        Console console= System.console();// creates a java Object which has method that allows us to write
        console.printf("Hallo parvel");
    }        
} 
It gives me the error:
Exception in thread "main" java.lang.NullPointerException
    at Introduction.main(Introduction.java:10)
/home/parvel/.cache/netbeans/8.1/executor-snippets/run.xml:53: Java returned: 1
BUILD FAILED (total time: 0 seconds). 
please help
 
     
     
    