title: work with text files in java
body: <p>I have just started learning java after C + +.
  but so far nothing is clear. especially the work with classes.</p>
  
  <p>tell me please how to open a file for reading or writing? it is desirable to provide the code completely.</p>
  
  <p>Thanks. sorry for bad english.</p>
  
  <p>upd: I started to learn java hour ago, but has not yet written a working program.</p>
  
  <p>Thank you all for your answers!</p>