The thing is I'm very new at this, like five days worth of new, and goto was the only thing I could find that made sense for the time being. I realize it was warned against. Do you have a suggestion...
Type: Posts; User: keeganstarr
The thing is I'm very new at this, like five days worth of new, and goto was the only thing I could find that made sense for the time being. I realize it was warned against. Do you have a suggestion...
Ahh gotcha, that makes sense. Thank you for all your help, I appreciate it and will give it a try.
Hmm, even though it is updating itself after each loop? How would I go about carrying that value from within the loop to outside so I can display it?
Okay so I would need to make the printf inside the loop to allow it to hold the correct value?
I didn't think that would, but it did. Now the only problem is its only displaying 1 as the value of p at the end instead of the total after the loop and math.
I'll show you the whole thing that way you will be able to understand why I'm doing what I am.
#include <cs50.h>
#include <stdio.h>
int
main(void)
{
days:
(D) is another input and the way the math played out it needed to be less than not equal to
yes there is. That may have helped, sry. P is also an inputed variable prior for the calculation information. That's why I am stuck. I cant find a way to replace it so that it continuously updates...
Hello, I'm trying to make a loop that will loop for the value that has been input and then continues to update a variable so that at the end it can spit out the total. The catch is I can't figure out...
Hmm... so simple. I tried == when I tried listing them on the same line but never after I separated them and that worked. Thank you!
Hello, I'm just starting this whole c programming and I've looked at alot of tutorials and still can't figure out a way to get this basic program to work properly. It keeps saying I have an error...