modified demo16