output code isolated into self-caling function scope