Skip to content

Instantly share code, notes, and snippets.

@Mashpy
Created September 30, 2013 10:01
Show Gist options
  • Save Mashpy/6761729 to your computer and use it in GitHub Desktop.
Save Mashpy/6761729 to your computer and use it in GitHub Desktop.
#include <iostream>
using namespace std;
class test
{
public:
char* a[4];
char* def();
};
char* test::def()
{
char* a[]={"aac","def","shc","hrg"};
return a[0];
}
int main()
{
test ob;
ob.a[0]=ob.def();
cout << ob.a[0]<< endl;
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment