Can we serialize the static variable?
Yes we can serialize the static variable.
if u don't want to serialize, u need to declare the variable as transient.
By default the fields declared as "static" or "transient" are not serialized. If there is still a requirement to serialize the static fields... you can do it by overriding readObject() and writeObject() method.
No We con't serialize static data. if you want real answer write serialization in one class and run the class after that you can write another class for deserialization and run the class then you get the real answer.
if you don't understand please read this post