// CA1.cpp : メイン プロジェクト ファイルです。
#include "stdafx.h"
using namespace System;
struct TTM1{
int V[7];
};
struct TTM2{
struct TTM1 t1;
struct TTM1 t2;
};
void T1VSet(TTM1 *a1,int Sv1[])
{
int w;
for(w=0;w<7;w++)
(*a1).V[w]=Sv1[w];
}
void T2VSet(TTM2 *a2,int Sv2[])
{
int w1;
int w2;
int RSv1[7];
int RSv2[7];
w1=(Sv2[1]+Sv2[4])/2;
w2=(Sv2[1]+Sv2[4])-w1;
RSv1[1]=w1;
RSv1[0]=w1+Sv2[0]-Sv2[1];
RSv1[2]=w1+Sv2[2]-Sv2[1];
RSv1[3]=Sv2[8];
RSv1[4]=Sv2[9];
RSv1[5]=Sv2[12];
RSv1[6]=Sv2[13];
RSv2[1]=w2;
RSv2[0]=w2+Sv2[2]-Sv2[1];
RSv2[2]=w2+Sv2[0]-Sv2[1];
RSv2[3]=Sv2[11];
RSv2[4]=Sv2[10];
RSv2[5]=Sv2[7];
RSv2[6]=Sv2[6];
T1VSet( &(*a2).t1,RSv1);
T1VSet( &(*a2).t2,RSv2);
}
int main(array<System::String ^> ^args)
{
struct TTM1 t1;
struct TTM2 t2;
struct TTM1 *M1ptr;
int Sv1[7]={0,10,20,30,40,50,60};
int Sv2[14]={100,110,120,130,140,150,160,170,180,190,200,210,220,230};
T1VSet(&t1,Sv1);
T2VSet(&t2,Sv2);
//t.V[0]=100;
//t2.t1.V[0]=110;
M1ptr=&t1;
Console::WriteLine("{0} {1} {2} {3} {4} {5} {6}",(*M1ptr).V[0],t1.V[1],t1.V[2],t1.V[3],t1.V[4],t1.V[5],t1.V[6]);
Console::WriteLine("{0} {1} {2} {3} {4} {5} {6}",t1.V[0],t1.V[1],t1.V[2],t1.V[3],t1.V[4],t1.V[5],t1.V[6]);
Console::WriteLine("{0} {1} {2} {3} {4} {5} {6}",t2.t2.V[0],t2.t2.V[1],t2.t2.V[2],t2.t2.V[3],t2.t2.V[4],t2.t2.V[5],t2.t2.V[6]);
Console::WriteLine("{0} {1} {2} {3} {4} {5} {6}",t2.t1.V[0],t2.t1.V[1],t2.t1.V[2],t2.t1.V[3],t2.t1.V[4],t2.t1.V[5],t2.t1.V[6]);
return 0;
}
#include "stdafx.h"
using namespace System;
struct TTM1{
int V[7];
};
struct TTM2{
struct TTM1 t1;
struct TTM1 t2;
};
void T1VSet(TTM1 *a1,int Sv1[])
{
int w;
for(w=0;w<7;w++)
(*a1).V[w]=Sv1[w];
}
void T2VSet(TTM2 *a2,int Sv2[])
{
int w1;
int w2;
int RSv1[7];
int RSv2[7];
w1=(Sv2[1]+Sv2[4])/2;
w2=(Sv2[1]+Sv2[4])-w1;
RSv1[1]=w1;
RSv1[0]=w1+Sv2[0]-Sv2[1];
RSv1[2]=w1+Sv2[2]-Sv2[1];
RSv1[3]=Sv2[8];
RSv1[4]=Sv2[9];
RSv1[5]=Sv2[12];
RSv1[6]=Sv2[13];
RSv2[1]=w2;
RSv2[0]=w2+Sv2[2]-Sv2[1];
RSv2[2]=w2+Sv2[0]-Sv2[1];
RSv2[3]=Sv2[11];
RSv2[4]=Sv2[10];
RSv2[5]=Sv2[7];
RSv2[6]=Sv2[6];
T1VSet( &(*a2).t1,RSv1);
T1VSet( &(*a2).t2,RSv2);
}
int main(array<System::String ^> ^args)
{
struct TTM1 t1;
struct TTM2 t2;
struct TTM1 *M1ptr;
int Sv1[7]={0,10,20,30,40,50,60};
int Sv2[14]={100,110,120,130,140,150,160,170,180,190,200,210,220,230};
T1VSet(&t1,Sv1);
T2VSet(&t2,Sv2);
//t.V[0]=100;
//t2.t1.V[0]=110;
M1ptr=&t1;
Console::WriteLine("{0} {1} {2} {3} {4} {5} {6}",(*M1ptr).V[0],t1.V[1],t1.V[2],t1.V[3],t1.V[4],t1.V[5],t1.V[6]);
Console::WriteLine("{0} {1} {2} {3} {4} {5} {6}",t1.V[0],t1.V[1],t1.V[2],t1.V[3],t1.V[4],t1.V[5],t1.V[6]);
Console::WriteLine("{0} {1} {2} {3} {4} {5} {6}",t2.t2.V[0],t2.t2.V[1],t2.t2.V[2],t2.t2.V[3],t2.t2.V[4],t2.t2.V[5],t2.t2.V[6]);
Console::WriteLine("{0} {1} {2} {3} {4} {5} {6}",t2.t1.V[0],t2.t1.V[1],t2.t1.V[2],t2.t1.V[3],t2.t1.V[4],t2.t1.V[5],t2.t1.V[6]);
return 0;
}
Replica Watches, Wholesale Replica Watches, Rolex Replica Watch Replica Franck Muller Watch