Skip to content

Instantly share code, notes, and snippets.

@yask123
Last active August 29, 2015 14:22
Show Gist options
  • Select an option

  • Save yask123/7b48c6a50cfd1eb87fbe to your computer and use it in GitHub Desktop.

Select an option

Save yask123/7b48c6a50cfd1eb87fbe to your computer and use it in GitHub Desktop.
c++ fstream and istream example
# include <iostream>
using namespace std;
class test
{
public:
static int f;
int x;
test()
{
f+=1;
}
};
int test:: f=0;
int main()
{
test a,b;
cout << test::f <<endl;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment