This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
using namespace std; | |
int a[100][100]; | |
int b[100][100]; | |
int main(void) { | |
ios_base::sync_with_stdio(false); | |
cin.tie(nullptr); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <vector> | |
#include <iostream> | |
using namespace std; | |
int n; | |
long long m; | |
vector<vector<long long>> mat; | |
vector<vector<long long>> base; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int main(void) { | |
int a = 0x01020304; | |
char *p; | |
p = (char *)&a; | |
for(int i=0; i<4; i++) { | |
printf("0x%02x\n", *(p + i)); | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int main(void) { | |
int i = 100; | |
double d = 3.14; | |
void* p = &i; | |
*(int*)p = 200; | |
printf("%d\n", i); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int main(void) { | |
int numArr[3][4] = { | |
{ 11, 22, 33, 44 }, | |
{ 55, 66, 77, 88 }, | |
{ 99, 110, 121, 132 } | |
}; | |
// int** numPtr = numArr; // ๊ฐ์ ์บ์คํ (int**)ํ๋ฉด ์คํ์ ๋์ง๋ง, ๊ฒฐ๊ตญ -๊ฐ์ ๋ฆฌํดํ๋ฉด์ ๋๋๋ค |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#if 0 | |
๋ฐํ๊ฐ์๋ฃํ ํจ์์ด๋ฆ(์๋ฃํ ๋งค๊ฐ๋ณ์[][๊ฐ๋กํฌ๊ธฐ]) | |
{ | |
} | |
๋ฐํ๊ฐ์๋ฃํ ํจ์์ด๋ฆ(์๋ฃํ(*๋งค๊ฐ๋ณ์)[๊ฐ๋กํฌ๊ธฐ]) | |
{ | |
} | |
#endif | |
#include <stdio.h> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <string> | |
#include <iostream> | |
using namespace std; | |
int score; | |
int frame[11], is_strike[11], is_spare[11]; | |
int totalsum(int frameNum) { // ์ด ์ ์ ๊ณ์ฐ | |
int sum = 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int frame[11], is_strike[11], is_spare[11]; | |
int score; | |
int totalsum(int frameNum) { | |
int sum = 0; | |
for (int i = 1; i <= frameNum; i++) { | |
sum += frame[i]; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#include <unistd.h> | |
int main(int argc, char **argv) | |
{ | |
return 0; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
int main(void) { | |
int arr[5] = { 1, 2, 3, 4, 5 }; | |
printf("(arr) addr : %p\n", arr); | |
printf("(arr + 1) addr : %p\n", arr + 1); | |
printf("(&arr + 1) addr : %p\n", &arr + 1); | |
return 0; | |
} |