removed warnings and sysouts; and replaced spaces with tabs