Order to reset

Report a typo

Adjust the steps to use the Reset Frame feature for the transferMoney() method.

public class MoneyTransfer {
    public static void main(String[] args) {
        double balance = 1000;
        double transferAmount = 600;
        double newBalance = transferMoney(balance, transferAmount);
        System.out.println("Account balance: " + newBalance);
    }

    private static double transferMoney(double balance, double transferAmount) {
        var newBalance = balance - transferAmount;
        updateBalanceInfo(newBalance);
        return newBalance;
    }

    private static void updateBalanceInfo(double newBalance) {
        System.out.println("Balance is updated. New balance: " + newBalance);
    }
}
Put the items in the correct order
Set a line breakpoint in the main method on the line executing "transferMoney()"
Click button "Reset Frame"
Step Into the "transferMoney()" method after resetting the frame
Step into "transferMoney()" method

Create a free account to access the full topic