Some piece of code for optimization.