Try-with-resources

Demonstrate try-with-resources functionality with the help of
java.lang.AutoClosable interface(available only from Java SE 7).