Hi. I'm trying to create a program to test my abilities (and it seems liek I need more practice :p) on what I've learned so far. I'm trying to calculate the circumference of a circle, with the user inputting their own diameter/radius. It compiles fine in my IDE with no errors, but when I select run, it crashes after I put my first thing.
It goes to command prompt, displays "Select r for radius or d for diameter: ", and when I press r, or d, it crashes saying "has stopped working properly. circumference.exe must close."
Your select function doesn't return anything, so it is essentially useless.
Your calculation function has weird parameters. You don't need to pass the select function into the calculation function at all, and it isn't done that simply anyway. When you call calculation, you give it no parameters at all.
I don't really see how this makes it through the compliler with no errors; there are a lot.