restuctured code