Yay! Thank you so much!!! I knew I was making it harder than what it should be. Thank you so much!
Type: Posts; User: kelleannmccan
Yay! Thank you so much!!! I knew I was making it harder than what it should be. Thank you so much!
motocross1, I don't know it you read my other reply to manasij7479, but I am trying to use pointer arithmetic to sum an array that has 10 elements. I appreciate the help you have given me, honestly.
I guess I didn't clearly state what I was doing. In my assignment I am to write a program that has an array of 10 elements and use pointer arithmetic to sum up all of the elements in the array. I...
I am sorry. I am now getting a negative number. It's very long. I did as you asked. Do I need a prototype? As you can see by my posts prior to this, I have problems understanding pointers.
yes I did. Still getting '0' for the sums.
I haven't changed much.
#include <iostream>
using namespace std;
//void explanation();
int sums;
It too is still giving the value of 0. I tried playing with that, giving the value of 55 (as what it should be) and it still came up with 0. Do you think it might be how I declared them?
I feel I'm getting closer! However, now it is saying the sum is 0. That's better than the 3294506849 I was getting!
I am writing a program for an array with 10 elements. I am trying to get the sum of all the elements in the array. I have thoroughly confused myself. Please look at my code and make suggestions as to...
While reading the code is much simpler than actually writing it, sometimes even reading is not so simple! Thank you!
I have two example codes:
array1.c example
int main ()
{
int test_scores[10];
int i;
I want to thank all of you for your answers! It worked! Something so simple that can cause such grief! Thanks again!
I am lost and confused at this moment.
The homework problem is Write a c program that calculates the average, the high and the low of the prices of a company's stock over a specified period of...