I liked this snippet about pointer misuse: void f(int n, int x) { Gadget* p = new Gadget(n); // look I'm a java programmer! :) // ... if(x
I rather prefer Java: void f(int n, int x) { Gadget p = new Gadget(n); // ... if (x Yes, good night's sleep tonight after writing that...
void f(int n, int x) {
Reader fr = new FileReader("foo.txt");
// ...
if (x
A garbage collector that gives a false sense of security is much worse than no garbage collector at all.