목록Summary/C(++) (10)
UOMOP
#include #define _CRT_SECURE_NO_WARNINGS #pragma warning(disable:4996) int main() { int arr[] = { 1, 2, 3, 4, 5, 6, 7, 8, 9 }; for (int i = 0; i < sizeof(arr) / sizeof(int); i++) printf("%d ", arr[i]); } #include #define _CRT_SECURE_NO_WARNINGS #pragma warning(disable:4996) int main() { int arr[] = { 1, 2, 3, 4, 5, 6, 7, 8, 9 }; printf("arr의 크기 : %d\n", sizeof(arr)); printf("int형의 크기 : %d\n", si..
#include #define _CRT_SECURE_NO_WARNINGS #pragma warning(disable:4996) int main() { int n; do { printf("제발 0을 눌러주세요!! : "); scanf("%d", &n); } while (n != 0); }
#include #define _CRT_SECURE_NO_WARNINGS #pragma warning(disable:4996) int main() { int choice; makechoice: printf("1 : new game\n"); printf("2 : load game\n"); printf("3 : setting\n"); printf("4 : credit\n\n"); printf("what? : "); scanf("%d", &choice); switch (choice) { case 1: printf("new game!\n"); break; case 2: printf("load game!\n"); break; case 3: printf("setting!\n"); break; case 4: prin..