Is it possible to call a static method of another class from a non static method without instance in java?
<p>Static methods are as close as possible to a global method. so why is this type of method call not possible? is there any other way to call the static method without instantiating the class??</p>

<pre><code>import java.io.*;
import java.util.*;
class pgm
{
    int x,v;
    static void func()
    {
        System.out.println("Function run");
    }
}
class egs
{
    public static void main(String args[])
    {
        pgm p=null;
        pgm.func();
        try
        {
            p.x=10;
            p.func();
        }
        catch(NullPointerException e)
        {
            e.printStackTrace();
        }

    }
}
</code></pre>