Your comments

TDD

Hi Alexander,

Sorry to up this thread, but are there any chances?

I was going to say the same Alexander says... when you have in one place, you can implement something like this:

Just to explain one thing, I've used number or null instead of just number think that in one hypothetical scenario the result can be zero, so it'll cache zero as well and not execute the complex calculation again.