cleanup before PR

restored 'f' checks for trailing zero
removed confusing comment
merged copy/paste function