Hey guys, my name is robyn and i am new to this site! i am having a bit of trouble coding arrays in c++. I know the basics an array, but am a little unexperienced when it comes to actually coding them. My teacher assigned us this problem:

int x[5], y[5], n[5] = {1,2,3,4,5};

Write a program that creates two new arrays. The first new array will square the elements of the original array. The second new array will be the sum of the corresponding array elements of the first two arrays. Here is what your output should look like:

Number Square Sum

1 1 2
2 4 6
3 9 12
4 16 20
5 25 30

If anyone can help me out a little, it would be sosoooo appreciated.


PS. If i get an A on this assignment i wouldn't be opposed to posting some hot pix of me