Here’s some advice to all who have just begun learning Java. This also serves as an overview to my blog, where I write about all kinds of misconceptions and common problems with programming in Java. Continue reading Dos and Don’ts
Some Mammals can fly. Dog extends Mammal, but it can’t fly. The term “extends” leads to some misconceptions. Continue reading Misconceptions about the “extends” Keyword
If you want to show some animation, maybe for a simple java game, then you need to render a certain amount of frames per second. For a smooth animation you want 30 to 60 frames per second. But sometimes the needed calculations need a bit longer so the delay until the drawing of the next frame needs to be shorter. For this an animation loop is needed. I have implemented a very simple animation loop for Java 8+ that can be paused and started.
Java doesn’t provide tuples. Here are some ideas what you can do about it. Continue reading Tuples in Java
So in Java there are many kinds of methods. I probably won’t even list half of them but I try to explain how different methods can be. Continue reading Types of Methods in Java
There’s a lot of confusion about “functions” in Java. Java doesn’t really have them, but an object could represent a function so it kind of does have them. I try to explain the different meanings of “functions” in Java, other languages and in mathematics.
Functional Programming made easy!
Continue reading Functional Programming in Java 8
Many things are outdated and better alternatives exist.
New is used to create new objects. But it’s used carelessly.
In Java you can only reference final fields inside a closure. Here’s my solution*. Continue reading Recursive Closures in Java