Storing the numbers in two arrays seems unnecessarily complicated; the OP just says you have to display the numbers in red or blue which you can do without any storage (except a loop variable).