I have a calculation (shown below):

total=(dogs + cats);

I want to be able to store the answer for total
I stupidly tried to put a cin statement underneath but that doesnt work.

when i used cin, my prog just waits for me to enter a value.

What would i use?

First you have to populate the two arrays dogs and cats. cin might be useful for that. After that is done then use a loop to sum them up