}
public int getBalance() {
return balance;
}
void add(){
int newbalance=balance+1000;
try {
Thread.sleep(1);
} catch (InterruptedException e) {
e.printStackTrace();
}
balance=newbalance;
}
}