I'm to use an array and strings to complete this.
#include <iostream>
#include <fstream>
using namespace std;
int main()
{
char names[25];
string input, first;
getline(cin, input);
first = input;
ifstream infile;
infile.open("names.txt");
infile >> names;
cout << names << endl;
system("PAUSE");
return 0;
}
right now I'm just trying to get it to print the names out and once I get that accomplished i will continue with how to get them printed out in alphabetic order!!!

New Topic/Question
Reply




MultiQuote








|