Simpler take

If performances are the same, then I suggest the following
shortening of code.