how to cast this?
Hi Folks!
I am new in java and trying to cast a long in integer. I am not sure what抯 wrong in my code?
Can anybody tell me what抯 wrong and how should I get it correct?
Here is my code.
Integer a1,b1;
Stack st =new Stack();
a1 = (Integer)st.pop();
b1 = (Integer)st.pop();
long x;
x=(long)a1;
sdos.writeLong(x);
dos.flush();
Thanks a lot in Advance.

