public static string username="Madam",password="Programming1",user,pass,select,loan,nloan,pangalan,d,namedebtor,loanuser,loanpass;
public static string address,contact,settingspass;
public static string fullnamess,contactss;
public static double bankmax=1000000000,sloan,interest,fake,amounteds;
public static int monthloan,re=0;
public static int[]opo=new int[10000000];
public static bool[]remover=new bool[10000000];
public static string[]alphabet={"a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","-",",",".","/","="};
public static string[]ploan=new string[10000000];
public static string[]cloan=new String[10000000];
public static string[]aloan=new String[10000000];
public static string[]loanerusername=new String[10000000];
public static string[]loanerpass=new String[10000000];
public static double [] [] jagged = new double[10000000][];
public static double[]amloan=new double[10000000];
public static double[]lsloan=new double[10000000];
public static double[]loanam=new double[10000000];
public static double[]mloan=new double[10000000];
public static double[]fakeloan=new double[10000000];
public static double[]deletors=new double[10000000];
public static double[]divide=new double[10000000];
public static double[]ihap=new double[10000000];
public static double[]balance=new double[10000000];
public static double[]amounted=new double[10000000];
public static double[]balanceds=new double[10000000];
public static void Main()
Console.WriteLine("--------WELCOME TO BANKING SYSTEM--------");
Console.WriteLine("[1]ADMIN\n[2]USER ");
Console.Write("Please Select: ");
select = Console.ReadLine();
Console.Write("Enter Username: ");
user = Console.ReadLine();
Console.Write("Enter Password: ");
pass = Console.ReadLine();
if(user.Equals(username)&&pass.Equals(password))
Console.WriteLine("Successfuly Log-in!");
Console.WriteLine("You missed it 3 times.\nSystem will now shut down...");
Console.WriteLine("Invalid Username/Password!");
else if(select.Equals("2"))
Console.WriteLine("Invalid Input!!!!.....");
public static void Admin()
Console.WriteLine("[1]New debtor\n[2]List of debtor\n[3]Payment\n[4]Settings\n[5]Check bankmoney\n[B]Back to main menu");
Console.Write("Please Select: ");
loan = Console.ReadLine();
else if (loan.Equals("2"))
else if (loan.Equals("3"))
else if (loan.Equals("4"))
else if (loan.Equals("5"))
else if (loan.Equals("B")||loan.Equals("b"))
Console.WriteLine("Invalid Input!\nPlease select:");
public static void NewLoaner()
for(int a = 0; a < ploan.Length;a++ )
if(ploan[a]==null&&cloan[a]==null&&aloan[a]==null&&lsloan[a]==0&&mloan[a]==0&&amloan[a]==0&&loanam[a]==0&&fakeloan[a]==0&÷[a]==0&&ihap[a]==0&&balance[a]==0&&amounted[a]==0)
Console.Write("Enter fullname of debtor: ");
pangalan = Console.ReadLine();
for(int v=0;v<ploan.Length;v++)
if(pangalan.Equals(ploan[v],StringComparison.OrdinalIgnoreCase))
Console.WriteLine("Fullname already exist please contact the debtor right now or enter another fullname.");
}while(pangalan.Equals(ploan[tttt],StringComparison.OrdinalIgnoreCase));
Console.Write("Enter contact number of debtor: ");
contact = Console.ReadLine();
for(int o=0;o<alphabet.Length;o++)
if(contact.Contains(alphabet[o]))
Console.WriteLine("Invalid input....Please do not include letters!");
}while(contact.Contains(alphabet[re]));
if(contact.StartsWith("09"))
Console.Write("Enter address of debtor: ");
address = Console.ReadLine();
Console.Write("Enter salary of debtor (per month): ");
loanam[0] = double.Parse(Console.ReadLine());
Console.Write("Enter months to pay: ");
monthloan =int.Parse( Console.ReadLine());
if(monthloan>=12&&monthloan<=60)
if(loanam[0]>=20000&&loanam[0]<=50000)
Console.WriteLine("You can loan 50,000-300,000");
Console.Write("Enter loan amount: ");
loanam[1] = double.Parse(Console.ReadLine());
if(loanam[1]>=50000&&loanam[1]<=300000)
Console.WriteLine("You cannot loan because bank money is below 1000000.BANKRUP!!!");
Console.WriteLine("\nSystem shut down....");
interest=amloan[a]*0.05*mloan[a]/12;
fakeloan[a]=fake+interest;
divide[a]=fakeloan[a]/mloan[a];
Console.WriteLine("By the end of {0} months the future value will be {1}.",mloan[a],fakeloan[a]);
Console.WriteLine("Successfully loaned {0}.",loanam[1]);
Console.Write("Enter username for debtors account: ");
loanuser = Console.ReadLine();
Console.WriteLine("Username's length must be 4 letters up!");
}while(loanuser.Length<4);
loanerusername[a]=loanuser;
Console.Write("Enter password for debtors account: ");
loanpass = Console.ReadLine();
Console.WriteLine("Password's length must be 4 letters up!");
}while(loanpass.Length<4);
for(int m=0;m<ploan.Length;m++)
if(loanpass.Equals(loanerpass[m],StringComparison.OrdinalIgnoreCase))
Console.WriteLine("Password is similar to other.Please chose another password....");
Console.WriteLine("Successfully registered!\n\nPress any key to continue......");
Console.WriteLine("Sorry salary and loan did not match.Try again!");
else if(loanam[0]>50000&&loanam[0]<=200000)
Console.WriteLine("You can loan 500,000-1,500,000");
Console.Write("Enter loan amount: ");
loanam[2] = double.Parse(Console.ReadLine());
if(loanam[2]>=500000&&loanam[2]<=1500000)
Console.WriteLine("You cannot loan because bank money is below 1,000,000.");
Console.WriteLine("\n\nPress any key to continue......");
interest=amloan[a]*0.05*mloan[a]/12;
fakeloan[a]=fake+interest;
divide[a]=fakeloan[a]/mloan[a];
Console.WriteLine("By the end of {0} months the future value will be {1}.",mloan[a],fakeloan[a]);
Console.WriteLine("Successfully loaned {0}.",loanam[2]);
Console.Write("Enter username for debtors account: ");
loanuser = Console.ReadLine();
Console.WriteLine("Username's length must be 4 letters up!");
}while(loanuser.Length<4);
loanerusername[a]=loanuser;
Console.Write("Enter password for debtors account: ");
loanpass = Console.ReadLine();
Console.WriteLine("Password's length must be 4 letters up!");
}while(loanpass.Length<4);
for(int m=0;m<ploan.Length;m++)
if(loanpass.Equals(loanerpass[m],StringComparison.OrdinalIgnoreCase))
Console.WriteLine("Password is similar to other.Please chose another password....");
Console.WriteLine("Successfully registered!\n\nPress any key to continue......");
Console.WriteLine("Sorry salary and loan did not match.Try again!");
else if (loanam[0]>200000)
Console.WriteLine("You can loan 1,500,000-5,000,000");
Console.Write("Enter loan amount: ");
loanam[3] = double.Parse(Console.ReadLine());
if(loanam[3]>=1500000&&loanam[3]<=5000000)
Console.WriteLine("You cannot loan because bank money is below 1,000,000.");
Console.WriteLine("\n\nPress any key to continue......");
interest=amloan[a]*0.05*mloan[a]/12;
fakeloan[a]=fake+interest;
divide[a]=fakeloan[a]/mloan[a];
Console.WriteLine("By the end of {0} months the future value will be {1}.",mloan[a],fakeloan[a]);
Console.WriteLine("Successfully loaned {0}.",loanam[3]);
Console.Write("Enter username for debtors account: ");
loanuser = Console.ReadLine();
Console.WriteLine("Username's length must be 4 letters up!");
}while(loanuser.Length<4);
loanerusername[a]=loanuser;
Console.Write("Enter password for debtors account: ");
loanpass = Console.ReadLine();
Console.WriteLine("Password's length must be 4 letters up!");
}while(loanpass.Length<4);
for(int m=0;m<ploan.Length;m++)
if(loanpass.Equals(loanerpass[m],StringComparison.OrdinalIgnoreCase))
Console.WriteLine("Password is similar to other.Please chose another password....");
Console.WriteLine("Successfully registered!\n\nPress any key to continue......");
else if(loanam[3]>5000000)
Console.WriteLine("Highest loan must be 5000000");
Console.WriteLine("Sorry salary and loan did not match.Try again!");
Console.WriteLine("Months to pay must be 12 months above 60 months below.");
Console.WriteLine("Invalid salary amount minimum is 20,000!.Please try again!");
Console.WriteLine("Contact number must be 11 digits. ");
Console.WriteLine("Contact number must starts with 09.");
public static void LoanerList()
for(int b=0; b < ploan.Length;b++)
Console.WriteLine("\nDebtor:{0}\nName: {1}\nContact Number: {2}\nAddress: {3}\nMonthly Salary: {4}\nLoan amount: {5}\nMonth to pay: {6}\nRemaining balance: {7}\nUsername: {8}\nPassword: {9}\n",yy,ploan[b],cloan[b],aloan[b],lsloan[b],fakeloan[b],mloan[b],balance[b],loanerusername[b],loanerpass[b]);
Console.WriteLine("Press any key back to menu or D if you want to delete data.");
if(d.Equals("D",StringComparison.OrdinalIgnoreCase))
Console.Write("Enter fullname of debtor: ");
namedebtor = Console.ReadLine();
for(int c=0;c < ploan.Length;c++)
if(namedebtor.Equals(ploan[c],StringComparison.OrdinalIgnoreCase))
Console.WriteLine("Are you sure do you want to delete {0} from the data?\nPress Y if yes any key back to menu...",ploan[c]);
string want = Console.ReadLine();
if(want.Equals("Y",StringComparison.OrdinalIgnoreCase))
Console.WriteLine("Successfully deleted {0}",namedebtor);
Console.WriteLine("\n\nPress any key to continue......");
Console.WriteLine("Sorry you cannot delete {0} data because it started its payment.You can delete the data if the debtor paid its corresponding fees..",namedebtor);
Console.WriteLine("\n\nPress any key to continue......");
else if(c==ploan.Length-1)
Console.WriteLine("Invalid Input!.Name of debtor not found.");
public static double[] pilapila=new double[10000000];
public static void Payment()
Console.Write("Enter the fullname of debtor: ");
string palautang = Console.ReadLine();
for(int d=0;d < ploan.Length;d++)
if(palautang.Equals(ploan[d],StringComparison.OrdinalIgnoreCase))
Console.WriteLine("Remaining balance is: {0}.",balance[d]);
Console.WriteLine("Monthly payment is: {0}.",divide[d]);
Console.WriteLine("Months to pay is: {0} months.",mloan[d]);
Console.WriteLine("Remaining months to pay is: {0} months.",ihap[d]);
Console.Write("Enter the amount of payment: ");
amounteds = double.Parse(Console.ReadLine());
if(amounteds<divide[d]&&balanceds[d]>divide[d])
Console.WriteLine("Invalid amount....Plss pay the corresponding payment");
}while(amounteds<divide[d]&&balance[d]>divide[d]);
totalic=amounteds-balance[d];
Console.WriteLine("Successfully paid {0}.",amounteds);
Console.WriteLine("Reamaining balance is {0}.",balance[d]);
Console.WriteLine("\n\nPress any key back to menu.....");
else if(balance[d]<divide[d]&&amounteds>=balance[d])
Console.WriteLine("Successfully paid loan amount");
Console.WriteLine("Your change is {0}",totalic);
Console.WriteLine("\n\n\nPress any key back to menu.....");
Console.WriteLine("Successfully paid loan amount");
Console.WriteLine("Your change is {0}",totalic);
Console.WriteLine("\n\n\nPress any key back to menu.....");
else if(d==ploan.Length-1)
Console.WriteLine("Invalid Input.Name of debtor not found.\n\nPress any key back to main menu....");
public static void Setting()
Console.WriteLine("[1]Change username\n[2]Change password\nElse back to menu.");
Console.Write("Select: ");
string selections = Console.ReadLine();
Console.Write("Enter current username: ");
string settingsuser = Console.ReadLine();
if(settingsuser.Equals(username))
Console.Write("Enter new username: ");
newusername = Console.ReadLine();
Console.WriteLine("Characters must be 4 above!");
}while(newusername.Length<4);
Console.WriteLine("Successfully change username from {0} to {1}",username,newusername);
Console.WriteLine("\n\nPress any key back to menu.....");
Console.WriteLine("Invalid username!!!");
Console.WriteLine("\n\nPress any key back to menu.....");
Console.Write("Enter current passowrd: ");
settingspass = Console.ReadLine();
if(settingspass.Equals(password))
Console.Write("Enter new username: ");
newpassword = Console.ReadLine();
Console.WriteLine("Characters must be 4 above!");
}while(newpassword.Length<4);
Console.WriteLine("Successfully change password from {0} to {1}",password,newpassword);
Console.WriteLine("\n\nPress any key back to menu.....");
Console.WriteLine("Invalid Password!!!");
Console.WriteLine("\n\nPress any key back to menu.....");
public static void Bankmoney()
Console.WriteLine("Bank money is {0}",bankmax);
Console.WriteLine("\n\nPress any key back to menu.....");
public static void User()
Console.Write("[1]Check balance\n[2]Payment history\n[3]Change Password\n[B]Back to main menu");
Console.Write("Select: ");
string selectss = Console.ReadLine();
else if(selectss.Equals("b",StringComparison.OrdinalIgnoreCase))
Console.WriteLine("Invalid input!");
public static void Login()
Console.Write("Enter your username: ");
fullnamess = Console.ReadLine();
Console.Write("Enter your password: ");
contactss = Console.ReadLine();
for(int e=0;e<ploan.Length;e++)
if(fullnamess.Equals(loanerusername[e],StringComparison.OrdinalIgnoreCase)&&contactss.Equals(loanerpass[e],StringComparison.OrdinalIgnoreCase))
Console.WriteLine("\n\nSuccessfully Log-in!");
else if(e==ploan.Length-1)
Console.WriteLine("Invalid username/password...\n\nPress any key to continue....");
public static void Checkbalance()
for(int f=0;f < ploan.Length;f++)
if(fullnamess.Equals(loanerusername[f],StringComparison.OrdinalIgnoreCase)&&contactss.Equals(loanerpass[f],StringComparison.OrdinalIgnoreCase))
Console.WriteLine("Remaining balance is: {0}.",balance[f]);
Console.WriteLine("Monthly payment is: {0}.",divide[f]);
Console.WriteLine("Months to pay is: {0} months.",mloan[f]);
Console.WriteLine("Remaining months to pay is: {0}.",ihap[f]);
Console.WriteLine("\n\n\nPress any key to continue....");
else if(f==ploan.Length-1)
Console.WriteLine("Fullname and contactnum not found.\n\n\nPress any key to continue....");
public static void Paymenthistory()
for(int g=0;g < ploan.Length;g++)
if(fullnamess.Equals(loanerusername[g],StringComparison.OrdinalIgnoreCase)&&contactss.Equals(loanerpass[g],StringComparison.OrdinalIgnoreCase))
Console.WriteLine("Total Payment is PhP: {0}",pilapila[g]);
else if(g==ploan.Length-1)
Console.WriteLine("\n\n\nPress any key to continue....");
public static void ChangePassword()
for(int h=0;h < ploan.Length;h++)
if(fullnamess.Equals(loanerusername[h],StringComparison.OrdinalIgnoreCase)&&contactss.Equals(loanerpass[h],StringComparison.OrdinalIgnoreCase))
Console.WriteLine("Enter current password: ");
string currentpassword = Console.ReadLine();
for(int i=0;i<ploan.Length;i++)
if(currentpassword.Equals(loanerpass[i],StringComparison.OrdinalIgnoreCase))
Console.Write("Enter new password: ");
newpasswordsss = Console.ReadLine();
if(newpasswordsss.Length<4)
Console.WriteLine("Password must be 4 letters up!");
}while(newpasswordsss.Length<4);
loanerpass[i]=newpasswordsss;
Console.Write("Successfully change password!\n\n\n");
Console.WriteLine("\n\n\nPress any key to continue....");
Console.WriteLine("Invalid Password!");
Console.WriteLine("\n\n\nPress any key to continue....");