본문 바로가기

Programming/C++124

[C] Struct, Initialization /*------------------------------------------------------------------------------------------@ Pratice C laguage Author : SAMCreated : 28-03-2017Modified : 28-03-2017Language/ver : C in MSVS2015 Description : PracticeKEYWORD : Struct, Initialization------------------------------------------------------------------------------------------*/ #include struct point {int x;int y;}; struct circle {stru.. 2017. 3. 28.
[C] Struct, Return, Function /*------------------------------------------------------------------------------------------@ Pratice C laguage Author : SAMCreated : 28-03-2017Modified : 28-03-2017Language/ver : C in MSVS2015 Description : PracticeKEYWORD : Struct, Return------------------------------------------------------------------------------------------*/ #include struct simple {int data1;int data2;};void show(struct si.. 2017. 3. 28.
[C] Struct, Inserting, Variables /*------------------------------------------------------------------------------------------@ Pratice C laguage Author : SAMCreated : 28-03-2017Modified : 28-03-2017Language/ver : C in MSVS2015 Description : Practice : Struct_Inserting KEYWORD : Struct, Inserting, Variables------------------------------------------------------------------------------------------*/ #include struct simple {int dat.. 2017. 3. 28.
[C] Struct CallBy /*------------------------------------------------------------------------------------------@ Pratice C laguage Author : SAMCreated : 28-03-2017Modified : 28-03-2017Language/ver : C in MSVS2015 Description : Practice : Struct_callby.c KEYWORD : Struct, callby------------------------------------------------------------------------------------------*/ #include struct simple {int data1;int data2;};.. 2017. 3. 28.
[C] Struct Reference /*------------------------------------------------------------------------------------------@ Pratice C laguage Author : SAMCreated : 28-03-2017Modified : 28-03-2017Language/ver : C in MSVS2015 Description : Practice : TelPhone1.c KEYWORD : Struct, Reference------------------------------------------------------------------------------------------*/ #include struct simple {int data1;int data2;}; .. 2017. 3. 28.
[C] Strunct, Pointer, Pointer /*------------------------------------------------------------------------------------------@ Pratice C laguage Author : SAMCreated : 28-03-2017Modified : 28-03-2017Language/ver : C in MSVS2015 Description : Practice : TelPhone1.c KEYWORD : Struct, Pointer(Pointer)------------------------------------------------------------------------------------------*/ #include struct person {char name[20];ch.. 2017. 3. 28.
[C] Struct, Pointer /*------------------------------------------------------------------------------------------@ Pratice C laguage Author : SAMCreated : 28-03-2017Modified : 28-03-2017Language/ver : C in MSVS2015 Description : Practice : TelPhone1.c KEYWORD : Struct, Pointer------------------------------------------------------------------------------------------*/ #includestruct person {char name[20];char phone[2.. 2017. 3. 28.
[C] Struct storing name and number at the same time /*------------------------------------------------------------------------------------------@ Pratice C laguage Author : SAMCreated : 28-03-2017Modified : 28-03-2017Language/ver : C in MSVS2015 Description : Practice : TelPhone1.c Showing sturct can including array also.------------------------------------------------------------------------------------------*/ #include #include struct person {c.. 2017. 3. 28.
[C] Struct distance example /*------------------------------------------------------------------------------------------@ Pratice C laguage Author : SAMCreated : 28-03-2017Modified : 28-03-2017Language/ver : C in MSVS2015 Description : Practice : distance1.c------------------------------------------------------------------------------------------*/ #include #include struct point {int x;int y;}; int main(void) {struct point.. 2017. 3. 28.
[C] 2 by 2 Matrix /*2차원 배열 선언과 초기화 연습하기.컴퓨터 그래픽 3D 작업에 사용된다고 하니 재미있겠다 > 2바이2로 고정해보고 하기. 쉽게2. 그거 받아서 그에 맞는 2차원 어레이 만들기3. 초기화 하기4. 값 받기5. 받은 값 잘 입력되었나 출력해보기6. 그 다음에 연산하면 된다네... */ #include #include int main(void) {int InputArray1[2][2], InputArray2[2][2];int i, j; for (i = 0; i < 2; i++){for (j = 0; j < 2; j++){printf("Matrix [%d] [%d] ", i, j);scanf_s("%d", &InputArray1[i][j], sizeof(InputArray1));}} for (i = 0; i.. 2017. 3. 10.