Has it really been 18 years since I did Java?
Last update on .
- You wrote 43 lines of code to define two methods, both of which are literally one-line calls that forward the call to another method?
- You wrote 30 lines of code to read the first line of a file and print it to stdout?
sure, I get it, you can pull in huge numbers of coders and chain them to the wagon... but seriously it seems 90% of their effort is pulling the wagon sideways against each other. I also realize that likely 99% of the code is actually written by some Eclipse plugin that generates meaningless boilerplate... but then you've got to maintain that cr*p forever or let it rot.
Comments are closed.
Pingbacks are closed.
Vincent Bernat on 10/30/2015 6:11 a.m. #
With Java 8, things got simpler. To print the first line of a file:
Stream<String> lines = Files.lines(Paths.get("/etc/passwd"));
Mike Fletcher on 11/02/2015 1:42 a.m. #
That still seems like someone is pulling your leg a bit. Better than the 30 lines of circuitous code, but when you're used to this:
print( open( '/etc/passwd' ).readline() )
it all just seems rather... pointlessly verbose.