So I'm having trouble with classes today, I want to do something like
#include <iostream.h>
using namespace std;
class Dummy{
char Name[256];
void setName(char nam){Name=nam;}
};
int main(){
char[256] temp;
cout << "Name?\n";
cin >> temp;
setName(temp);
}
I want something like this to store a char array in a class, but it never works, I've googled all this stuff and just cant find it, Help!