Skip to content

Commit a5b1763

Browse files
committed
Drop implementation details from instructions.append.md
The implementation details should be understandable from the stubs and tests.
1 parent 2a5f78d commit a5b1763

File tree

1 file changed

+0
-31
lines changed

1 file changed

+0
-31
lines changed

exercises/practice/bank-account/.docs/instructions.append.md

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,36 +1,5 @@
11
# Instructions append
22

3-
## Implementation Notes
4-
5-
### Opening an account
6-
7-
An account can be opened.
8-
On opening, its initial balance should not be negative.
9-
If a negative balance is given to the `Open` function, `nil` must be returned, otherwise the newly created account must be returned.
10-
11-
### Closing an account
12-
13-
An account can be closed.
14-
When closing an account, the `Close` method must return the balance the account has and a boolean `true` indicating the account was closed successfully.
15-
Closing an account does not succeed if the account is already closed.
16-
When an account is closed, its balance must be set to `0`.
17-
18-
### Getting the account balance
19-
20-
The `Balance` method allows a user to check the current balance of an account.
21-
It must return the balance of the account and a boolean indicating if the operation succeeded.
22-
Checking the balance only doesn't succeed if the account is closed.
23-
24-
### Deposits / Withrawals
25-
26-
Deposits and withdrawals are both handled by the `Deposit` method.
27-
If the argument given to the method is a positive amount, then that amount of money must be deposited in the account.
28-
If the amount given is negative, that amount of money must be withdrawn from the account.
29-
If the account is closed, its balance must not be modified.
30-
31-
`Deposit` returns the new balance of the account and a boolean that indicates if the operation succeeded.
32-
`Deposit` must fail if the account is closed or if there is not enough money to withdraw from the account.
33-
343
## Testing
354

365
The tests will execute some operations concurrently.

0 commit comments

Comments
 (0)