Category Archives: Talk

Talk about politics, society, science, computers, internet, psychology, and philosophy.

Programming Course from hell

Today we visit a fictional “Java Programming 101” course where both the pupils and the teacher are from hell…

Why is it called “class”? Is there some kind of hidden political meaning here?

It’s a public class so, don’t worry…

But, I can still change it, so it’s not really final in the first place… it should be called “kind of final”… but that won’t compile…

Oh, it really is final, but when you change it the universe splits in two. In one universe the code is still final and unchanged and in the other the code is final and changed. In one of the universes a cat will also die, so please try not to change final code too often…

What if I wanted to use “what if” instead of “if”? Then I get compilation errors… What if I want it to work?

What if you learned to program and programmed a compiler where “what if” didn’t cause a compilation error?

How do I change a volatile variable? I don’t want shit to go crazy or anything!

If you encapsulate the modification operations, you’re safe…

I do not want to use static. It’s a huge mistake. You’ll probably miss business opportunities and go bankrupt in a year. Static is the first step to death!

Not to worry! If you only use “static” in agile programming it’ll sort itself out.

Since my programming problem is far from superficial I need to use something far less flimsy than “floats”, and I am fairly certain “double”-ing down is not the right way to go!

This problem needs byte arrays and bitwise operators.

If “void” truly was a void, would there even be a word for it?

The true void is such a vast and complex mystery a simple human mind can never comprehend its full meaning and our only hope lies in the application of simplistic symbols.

This is insane! I try to catch using grep but once I’ve serialized the exceptions I don’t know how to find the regex from the catch clause!

Have you tried to decompile the class-file first?

Shouldn’t you install the plumbing before you open any streams? I don’t want a total mess…

Streams have pipes and terminators to help with that…

Come on, you’ve seen Windows! You already know there’s no logic to this!

What if my transient variable decides to move to another class?

Just make it private and it’ll stay private…

I looked through the code of the jre last night and I’ve deduced that synchronized methods aren’t synchronized at all! They should be called unsynchronized!

You should look into reprogramming the jre to make them truly synchronized…


Header image: By PIXNIO