Ad
  • Custom User Avatar

    You saved my day bro) I started month from 0 and it is not right. Many thanks !!!

  • Custom User Avatar

    @FArekkusu: thanks, I can't say better!

  • Custom User Avatar
    1. Isn't it logical that the percentage should be updated before applying any changes to the cost?
    2. Selling, buying and saving are normally done at end of month - if you think of your months counter as "number of months that have passed", everything is correct because only 1 month passed, NOT 2, and you should not adjust anything.
    3. You're just duplicating your question #1 here.
    4. You're duplicating your question #2 again.
    5. "766 is the nearest integer to 766.158..." -> "nearest integer" -> use round.
    6. The Parameters and return of function part clarifies that all the mentioned values are parameters to the function.

    Not an issue, but question. If 4000 people understood the task while you do not, that's your problem.