storing output in a variable