will do
Type: Posts; User: andyouf
will do
Haha, yes Jim, I was trying to take all the credit for this incredibly complex beginner C prog in order to impress all. I realize it is not good from to post duplicates.
Anyway, I got my answer...
I got it, it was parameter error and me putting calc in front of statements in calc function. Thank you.
Hi, getting two small errors in lines 95 and 97 with semicolon but everything looks fine.
The issue is that my program works fine without the "calc" and "printResult" functions but these are...
My gosh these are such simple errors! I panic and think it is some huge coding error or that I don't understand application of parameters (which I need to review, completely). Thank you!
Onto...
it does not compile...I am going to review your #79 post and make sure I understand. I don't understand many of the compile errors I get so maybe this will help for future errors.
yes, good point, not even compiling :) okay the semicolon has been added and yes i need to quit thinking of this like a paper or something I can proofread after....i get declaration errors on lines...
Besides adding "int minimum" to my function declaration, I don't see what the compiler is telling me.
Crashing like crazy, even on things that work in other instances of the program I have open. This is not in reference to "void" in reference to getting smallest # function to work.
/* Prompts...
Thank you, working on this.
On not putting return type as void in my function when I try changing that and the function declaration to void it kept crashing my IDE?
I'm baffled, I've tried switching variables, parameters.
/* Prompts user and gets integer numbers from keyboard, one number at a time. Ends program when 99999 entered and displays various...
This is maddening. I don't get why my current_smallest function does not work.
/* Prompts user and gets integer numbers from keyboard, one number at a time. Ends program when 99999 entered and...
i just rewrote with your much more efficient code. That is brilliant and I see what you did and what was prevented. Now I'm upset that I have to take it out and make it a function. Or some of it.
okay i see about the scope and proplem with something being +99999...that did not make sense and yes I need to start formatting properly from the beginning this is much easier to work with. My...
I get it, thank you. The only thing I don't understand is why you use "number_ptr" instead of just "number" at the beginning of the function.
/* Prompts user and gets integer numbers from...
This was really helpful...thank you much.
The code does not crash, but it outputs: "Enter next integer: minimum number is 99999"
That's a great tip Salem, you're right and it is confusing following both. Sry about that.
Ok now it works but it is keeping a running tab of the minimum integer ie enter "new integer...minimum is".....I was looking for Enter new integer to keep repeating and then program output after...
actually if I change this printf("minimum number is %d\n"), minimum); to printf("minimum number is %d\n"), getNumber;
the program does not crash put also won't display minimum number stmt.
i get multiple errors when I try your if stmt. why do you initialize minimum to 99999?
{
int getNumber;
int average;
int sum = 0;
int loop_count = 0;
int minimum=99999;
getNumber shld just take one address parameter so that integer from keyboard is picked up...
#include <stdio.h>
#include <stdlib.h>
//function declarations
I am trying to find a way to put a getSmallest function in here so that it will output smallest integer entered. If it is just an arbitrary amount of #'s and I don't know what will be entered I am...
My professor wants getNumber to be a function that takes in an address parameter so that the integer entered in keyboard is picked up. I have that down but I don't see how to make this a separate...