(Jul-10-2018, 11:26 AM)Prabakaran141 Wrote: you can also declare the variable "yearAt100" globally and access it anywhere in the program,Using globals is considered bad practise and generally discouraged. Please, don't suggest that and don't use it in your code. And just for completeness - if you do use globals, your function does not need the return statement. But again, don't do that.
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs