change structure to two ways