improved BGT example