formatted code to comply to CP+B coding style