All pastes #564980 Raw Edit

Untitled

public cpp v1 · immutable
·published 2007-06-13 20:22 UTC
rendered paste body
#include <iostream>#include <iomanip>using namespace std;const long CinStrLen(long * puiLength){	char ch = 0;	cin.get(ch);	cout << "c = " << ch;	if(ch != '\n')	{		cout << endl;		CinStrLen(puiLength);		*puiLength += 1;		cout << "c = " << ch << endl;			}	cin.putback(ch);	return *puiLength;}int main(void){    long *p = new long();    CinStrLen(p);    cout << "length = " << *p;    char *z = new char (*p+1);    cin >> z;    cout << endl << z << endl << "bye"<< endl;    delete p;    cin.get();}