Newbie needs thread lib sample code