working on c_out and local vars