Pointers
While I already knew most of these stuff, I’m still taking notes here as I did not know how to use memory stuff with C or C++.
Array
int arr[3] = { 1, 2, 3 };
printf("arr Size: %zd bytes\n", sizeof(arr));
printf("arr Address: %p\n", arr);
for (int i = 0; i < 3; ++i) {
printf("arr[%d]: %d(%p)\n", i, arr[i], &arr[i]);
printf("*(arr + %d): %d(%p)\n", i, *(arr + i), arr + i);
}
So, arr[n] equals to *(arr + n),
which is why accessing Array is O(1).
Pointer
The Pointer is only a thing in C and C++.
int* dest = arr; // array stores pointer
printf("dest: %d\n", *(dest + 1)); // pointer + int: increment by data size
// & to get memory address pointer, * to access memory using pointer
And the size of pointer is 8 Bytes, unless it’s 32 bits environment then 4 Bytes.
You mark * at the end of the data type to specify that it’s pointer type.

Hey, I can understand this meme now.
Also this can be used for string in C.
char str0[5] = "Test"; // static array
char* str1 = "Test"; // dynamic array
printf("%c\n", str0[1]);
printf("%c\n", str1[1]);
In C#, the size of array is defined on initialization. But in C and C++, you usually do that as you declare variables.
Multi dimensional Array
int arr1D[6] = {11,12,13, 21,22,23};
int arr2D[2][3] = {
{11,12,13},
{21,22,23}
};
They are just fancier 1D array, but what kind of fancy?
for (int i = 0; i < 2 * 3; ++i) {
printf("arr2D + %d: %d(%p)\n", i, *(*arr2D + i), *arr2D + i);
}
Unlike 1D array which is a pointer, 2D array is a pointer of pointer.
So that equals to this:
int makeArr1D[6] = {11,12,13, 21,22,23};
int* arr0 = &makeArr1D[0];
int* arr3 = &makeArr1D[3];
int* makeArr2D[2] = { arr0,arr3 };
int** arr2D = makeArr2D;
Call by Value or Reference
So, the major difference b/w class and struct in C# is:
class uses Call by Reference and
struct uses Call by Value.
This Call by Value/Ref difference is what creates that whole Shallow/Deep Copy thing.
Now this is very important as we need to differentiate whether we’re doing shallow copy or not, especially when we want to edit the copy.
(This is why I often make Clone(this type self) function to ensure Deep Copy)
Books
I bought these for now:

My method of studying algorithms is mostly Baekjoon and googling Baekjoon whenever I encounter new tags.
Also Refactoring. I’m intrigued.
The way I usually do that is: do exception handling first. This reduces layers of indents.
Those are bought from an used book market so it’ll take a week or two to arrive.