I have a Person object with 5 variables and I want to store
them in a file called Person.txt. What should I do?

Answer Posted / s.ramesh

We have to implement serializable interface

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Is oracle java 11 free?

535


Explain, java is compatible with all servers but not all browsers?

619


What is the difference between the Reader/Writer class hierarchy and the InputStream/OutputStream class hierarchy?

648


How big is a gigabyte?

624


What is the use of protected in java?

542






What is the default access specifier for variables and methods of a class?

576


How to set the permissions to a file in java?

544


What about interrupt() method of thread class ?

597


Difference between a process and a program?

621


Why wait and notify methods are declared in object class?

611


How do you escape json?

546


Explain illegalmonitorstateexception and when it will be thrown?

627


What is data and its types?

580


What is the difference between sleep and wait in java?

521


What are runtime exceptions?

624