I'm a newbie in c++ and i'm writing a prog to exchange from a currency to another.
In my prog i use a variable and an array in almost all my functions, so my question is if it would be better to declare them both as global, so that they were visible to all and i didnĀ“t need to pass them as arguments to functions, or, instead, as local to main and pass them as arguments in function calls.
No. It's almost always never better to use globals.
It may seem reasonable in the context your write the code, but it's a maintenance nightmare, and parts of your code is coupled the globals, making it difficult to reuse that code in other programs.