the codes written to hold only one character in the char variable. if you do this:
Code:
#include <iostream.h>
char user[256], pass[256];
int main(int argc, char *argv[])
{
cout <<" Project Communication Service\n";
cout <<" Private Message bot v1.0\n\n\n";
cout <<"LOGIN\n";
cout <<"Username: ";
cin>>user;
cout << "Password: ";
cin>>pass;
return 0;
}
the char variables are now character arrays, and will hold up to 256 letters. Cin isn't really the right use here, so we'll use cin.getline like this:
Code:
#include <iostream.h>
char user[256], pass[256];
int main(int argc, char *argv[])
{
cout <<" Project Communication Service\n";
cout <<" Private Message bot v1.0\n\n\n";
cout <<"LOGIN\n";
cout <<"Username: ";
cin.getline(user,256);
cout << "Password: ";
cin.getline(pass,256);
return 0;
}