bankacoount code #66
Unanswered
Mallikarjunahugar
asked this question in
Q&A
Replies: 1 comment
|
Please submit it under the appropriate discussion and then you can also delete this solo discussion from here. @Mallikarjunahugar |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
package bank;
import java.util.*;
public class Bankaccount {
int ac_no;
String name, type;
float amount;
}
void details(int n,String nm,String t, float a)
{
ac_no=n;
name=nm;
type=t;
amount=a;
}
void show()
{
int name;
System.out.println(ac_no+" ",+name+" ",+type+" ",+amount);
}
void deposit(float a)
{
amount+=a;
System.out.println("deposit amount");
}
void withdraw(float a)
{
if(amount<a)
{
System.out.println("Insufficient amount");
}
class test{
{
bank b=new bank();
b.details(123456,"Arjuna","Saving account",1001);
b.show();
b.deposit(2001);
b.checkbalance();
b.withdraw(1500);
b.checkbalance();
}
}
All reactions