<s>[INST] The following is a code snippet from a simple banking system that allows users to deposit and withdraw money:
```
class BankAccount:
    def __init__(self, balance=0):
        self.balance = balance

    def deposit(self, amount):
        if amount > 0:
            self.balance += amount
            return True
        return False

    def withdraw(self, amount):
        if 0 < amount <= self.balance:
            self.balance -= amount
            return True
        return False

    def __str__(self):
        return f"Account balance: {self.balance}"
```
However, the system currently does not handle cases where the user wants to transfer money between accounts. The task is to extend the class to support this functionality.

Here's an example of how the `transfer` method should behave:
```
account1 = BankAccount(100)
account2 = BankAccount(50)

account1.transfer(account2, 20)
print(account1)[/INST]