The procedural method: $balance = add_to_acct($balance, $amount); The OOP method: my $acct_obj = new BankAccount($initial_balance); $acct_obj->add_to_acct($amount);