Originally posted by dajac chison:
Which way is better ? Which way faster and need less "memory"?
That is not important. The logic is different between the two ways.
In #1 way the second method will not be called if the first method throws an IOException.
However in your #2 way the second method will be called whether or not the first method threw an Exception.
You need to decide what behaviour you want. For example if you want to open and read from a file, there is no point in calling read if the open threw a FileNotFoundException so #1 would be appropriate. In other situations #2 would be better.
Your English is quite understandable, no need to be sorry.