1
2
3
4
5
6
7
$ javac CastDouble.java 
CastDouble.java:4: inconvertible types
found   : java.lang.Object
required: long
        double d= (long)o;
                        ^
1 error