annotated logic; removed unused code