presentation version
rearrange codes