Also the recursion (calling main() at the end of main), should be avoided when the problem can be solved another way.
here are my suggestions
Code:
#include <iostream>
#include <fstream>
using namespace std;
int main()
{
int choice;
char crt[90];
//char eee[5];
// Unneccessary as of yet
cout<<" Welcome to the new banking program \n";
cout<<"---------------------------------------------------------------------\n";
cout<<"Please choose from the below options:\n";
cout<<"1. Create a new account.\n";
cout<<"2. Open an existing account.\n";
cout<<"3. Edit an existing account.\n";
cout<<"4. Information about the programmer.\n";
cout<<"5. Quit.\n";
cout<<"----\n";
cout<<"Your Choice: ";
cin>>choice;
cin.ignore();
cout<<" -------------------------------------------------------------\n";
if(choice==1)
{
cout<<"Please type in your account name:\n";
cin.getline(crt, 90);
ofstream a_file(crt, ios::noreplace);
// just crt here will do what you expect, create a file with the name crt
}
cout << "The name of your new account: " << crt << endl;
return 0;
//main(); recursive, and with no "break" to stop is a bad idea
}
Ultimately, if you plan to expand the menu and include all the options, I would reccomend that you look into the subject of Object-oriented-programming (OOP), and Classes.
-- Placid