"Mr. Charles has a credit card with a balance of RM100 to settle and has been charged by the bank a 2% monthly interest. Write a program using a repeat/until to calculate how many months can Mr. Charles pass without making any payments before his balance exceeds RM200"
int balance = 100;
int month = 0;
do {
// additional code required here
month++;
} while (balance < 200);
Inside the loop you need to increase the balance by 2%.
You might instead want to work using pennies or cents, and thus use 10000 and 20000 as the figures. It may not affect the outcome, but you might also need to consider rounding the figure rather than truncating it each time,