Improved example script