// ConsoleApplication1.cpp : Defines the entry point for the console application.
//

#include "stdafx.h"
#include "iostream"
using namespace std;
typedef struct alan
{
	int i;
	char c;
	double d;
}A;

int _tmain(int argc, _TCHAR* argv[])
{
	A p1;
	A *p2=(A*)malloc(sizeof(A));
	A *p3=(A*)malloc(sizeof(A)*10);
	cout<<p2->c<<"\t"<<p2->d<<"\t"<<p2->i<<endl<<endl;
	p1.c='c';
	p1.d=1025.15;
	p1.i=6;
	p2->c='x';
	p2->i=10;
	p2->d=50e+50;
	p3[0].c='s';
	p3[0].d=99.99;
	p3[0].i=25;
	cout<<p1.c<<"\t"<<p1.d<<"\t"<<p1.i<<endl<<endl;
	cout<<p2->c<<"\t"<<p2->d<<"\t"<<p2->i<<endl<<endl;
	for(int i=0;i<10;i++)
	{
	cout<<p3[i].c<<"\t"<<p3[i].d<<"\t"<<p3[i].i<<endl<<endl;
	}
	system("pause");
	return 0;
}

