티스토리 뷰
참고 :
#include <stdio.h>
#include <stdlib.h>
#include <tchar.h>
#include <windows.h>
struct x {
INT32 a;
INT32 b;
INT32 c;
};
int _tmain(INT32 argc, LPTSTR argv[]) {
struct x x1 = {0};
_tprintf(_T("%d %d %d \n"), x1.a, x1.b, x1.c);
struct x x2;
memset(&x2, 0, sizeof(x2));
_tprintf(_T("%d %d %d \n"), x2.a, x2.b, x2.c);
return EXIT_SUCCESS;
}
/* Output
0 0 0
0 0 0
*/
'Piece' 카테고리의 다른 글
Class [Python] allocator __new__ & initializer __init__ & finalizer __del__ (0) | 2018.06.30 |
---|---|
[Python] Check Package Dependencies (0) | 2018.06.30 |
[C] GetCurrentDirectory GetWindowsDirectory GetSystemDirectory (0) | 2018.06.25 |
Array [C# Java] 1 Dimensional Array Initialization (0) | 2018.06.24 |
switch [C# C++ Java] fall through (0) | 2018.06.24 |