iterate through result and print it