instance variable
how do i declare a variable called decBalance which will contain the initial R1000 and the updated account balance when the user deposits or withdraws money?
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
AlanPosted Aug 16, 2007, 9:37 AM
// declaration
decimal decBalance = 1000m;
// update with a new value, after a deposit of R200 say:
decBalance += 200m;