Hello, I'm new to the site here. I say this because there seems to be a fair bit of etiquette here that I could step on so if I do, that's why.
Anyhow, I had to take C for my software certificate and since I wanted to take C++ and couldn't, I'm trying to self teach it to myself. I'm doing that by essentially going through my old C book and writing the homework problems in C++ instead so that explains the simplicity of this first question.
1. Ok, I hope I do this right... I have a C problem that asks for you to take in a character from the keyboard. It then wants me to print it twice, once as a character (%c) and then again as an integer (%d) and I can do that without batting an eye. I am not, however so familiar with the cout and cin commands. I was able to reproduce the results by using a cast in the cout statement but I need to know if there is an equivalent of the type specifier (%d) or if I should just use the cast.
2. The second one is more theoretical. I've read a fair bit about C/C++ and other languages that a MAIN function. In every tutorial or book there comes a point where the book will say something like "When you write larger programs, Main will consist only of function calls." My question is, how literal is that statement supposed to be taken? Does that mean that there should be no variables defined in Main? Does it mean that if there are four lines of code that they should all be function calls.
I'm sorry if these are odd questions or worse yet.. repeated questions but I have looked around and wherever I've looked it is assumed that this is known in the same way it is assumed that I breathe and walk upright.
Thanks in advance.