{"id":11,"date":"2026-08-17T15:30:53","date_gmt":"2026-08-17T15:30:53","guid":{"rendered":"https:\/\/corpusgame.com\/?p=11"},"modified":"2026-08-17T15:30:57","modified_gmt":"2026-08-17T15:30:57","slug":"c-basic-reference-template-allocate","status":"publish","type":"post","link":"https:\/\/corpusgame.com\/en\/c-basic-reference-template-allocate\/","title":{"rendered":"[C++ Basic] Reference, Template, Allocate"},"content":{"rendered":"<h2 class=\"wp-block-heading\">Introduction<\/h2>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">To study C++ basics, you need to understand the fundamental differences from other languages. Those differences lie in memory management, handling original variables, and dealing with addresses. Moving forward, we will learn about these concepts in C++.,<\/p>\n<\/blockquote>\n\n\n\n<h2 class=\"wp-block-heading\">C++ Basics: Difference between Static Allocation and Dynamic Allocation<\/h2>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">I will organize this because it's a very basic concept that you shouldn't not know, but it can still be confusing.<\/p>\n<\/blockquote>\n\n\n\n<p class=\"wp-block-paragraph\">Static allocation and dynamic allocation are related to compilation; if the memory size and location are determined at compile time, it is static allocation, and if they are specified during runtime, it is dynamic allocation.<\/p>\n\n\n\n<p class=\"wp-block-paragraph\">For reference, since static allocation is stored on the stack and dynamic allocation is stored on the heap, it remains in memory even after the function ends, so you must always deallocate it.<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img loading=\"lazy\" decoding=\"async\" width=\"411\" height=\"485\" src=\"https:\/\/corpusgame.com\/wp-content\/uploads\/2026\/08\/image.png\" alt=\"\" class=\"wp-image-15\" srcset=\"https:\/\/corpusgame.com\/wp-content\/uploads\/2026\/08\/image.png 411w, https:\/\/corpusgame.com\/wp-content\/uploads\/2026\/08\/image-254x300.png 254w, https:\/\/corpusgame.com\/wp-content\/uploads\/2026\/08\/image-10x12.png 10w\" sizes=\"auto, (max-width: 411px) 100vw, 411px\" \/><\/figure>\n\n\n\n<pre class=\"wp-block-code\"><code>int main() {\n    int n;\n    cout &lt;&lt; \"\ubc30\uc5f4 \ud06c\uae30 \uc785\ub825: \";\n    cin &gt;&gt; n;\n\n    \/\/ \ub3d9\uc801\uc73c\ub85c \ubc30\uc5f4 \ud560\ub2f9\n    int *arr = new int&#091;n];\n\n    \/\/ \ubc30\uc5f4 \ucc44\uc6b0\uae30\n    for (int i = 0; i &lt; n; i++) {\n        arr&#091;i] = i * 10;\n    }\n\n    \/\/ \ubc30\uc5f4 \ucd9c\ub825\n    for (int i = 0; i &lt; n; i++) {\n        cout &lt;&lt; arr&#091;i] &lt;&lt; \" \";\n    }\n    cout &lt;&lt; endl;\n\n    \/\/ \ub3d9\uc801 \ud560\ub2f9 \ud574\uc81c\n    delete&#091;] arr;\n    \/\/ \uac12 \ud0c0\uc785\uc774\uba74 delete\n\n    return 0;\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Because it is impossible to change the size of an array at runtime, dynamic allocation must be used to receive input from the user and set the size. With static allocation, it is impossible to change the size of an array by receiving input from the user.<br>\u26a0\ufe0f You must free the memory using delete[] \u2013 since the memory was allocated as an array, it must be deallocated as an array.<br>General variables are freed with delete.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Functions and Structures<\/h2>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">Of course I know functions and structs, but what is C++? Isn't it a language that deals with memory? That's why we could change values by using pointers as a way to pass values to functions.<\/p>\n<\/blockquote>\n\n\n\n<h3 class=\"wp-block-heading\">function parameters<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>void changeValue(int *ptr) {\n    ptr += 5;\n}\n\nint main() {\n    int num = 10;\n    std::cout &lt;&lt; &quot;num before change: &quot; &lt;&lt; num &lt;&lt; std::endl; \/\/ 10\n\n    changeValue(&amp;num);  \/\/ Pass the address of num\n\n    std::cout &lt;&lt; &quot;num after change: &quot; &lt;&lt; num &lt;&lt; std::endl; \/\/ 15\n\n    return 0;\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">In this way, you can pass the address of a value type and modify it as desired.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>void changeValue(ref int number) {\n    number++;\n}\nint x = 5;\nchangeValue(ref x);  \/\/ x is now 6<\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>void changeValue(out int a) {\n    a = 10;\n}\nint y;\nchangeValue(out y);  \/\/ y is now 10<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">For reference, in C# as well, <code>ref<\/code>\uc640 <code>out<\/code> You can change the value using keywords, <code>ref<\/code>is that initialization must be performed <code>out<\/code>is that you don't have to do it.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">struct<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>struct Person{\n    string name;\n    int age;\n    float height;\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If you created a struct like this, you need to access it<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Person adult;\nadult.name = \"yoon\";\nadult.age = 24;<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">If it is statically allocated like this, the individual members inside the structure <code>.<\/code>can be accessed using.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Person *adult = new Person;\nadult -&gt; name = \"yoon2\"\nadult -&gt; age = 23;<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Dynamic allocation is <code>-&gt;<\/code>It must be accessed using.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Person* arr = new Person[3];\narr[0].name = \"Alice\"; \/\/ Using the . operator\narr[1].age = 25;<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">For your information, when accessing array elements, both static and dynamic methods are used. <code>.<\/code>is used.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Constant<\/h2>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">In C#, you can create constants using `const` and `readonly`; similarly, in C++, you can create constants using `const`. (`readonly` is not supported.)<br>Reference variable<\/p>\n<\/blockquote>\n\n\n\n<h3 class=\"wp-block-heading\">Pointer variables and constness<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>int main() {\n    int a = 2;\n    const int *ptr = &amp;a;\n\n    a = 1; \/\/ Compiles successfully\n    *ptr = 10; \/\/ Error\n}<\/code><\/pre>\n\n\n\n<ul class=\"wp-block-list\">\n<li>If you make a pointer variable a constant, you cannot change the value through the dereference operator.<\/li>\n<\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code>int main() {\n    int a = 2;\n    int b = 1;\n    int *const ptr = &amp;a;\n\n    a = 10; \/\/ Compiles successfully\n    ptr = &amp;b; \/\/ Error\n}<\/code><\/pre>\n\n\n\n<ul class=\"wp-block-list\">\n<li>If you make the pointer variable itself constant, you cannot change the variable that the pointer variable references.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Reference variable<\/h2>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">Referencing the original variable rather than the memory address.<br>In c#, `ref` and `out` are reference variables, that is, reference variables.<br>When representing reference variables, the &amp; is sometimes placed in front of the variable name, but since this is easily confused with the syntax for pointing to a pointer's address, it is standard practice to distinguish them by placing the &amp; right after the type instead.<\/p>\n<\/blockquote>\n\n\n\n<pre class=\"wp-block-code\"><code>\/\/ Declare parameters as reference variables\nvoid swap(int&amp; ref_a, int&amp; ref_b) {\n    int temp = ref_a;\n    ref_a = ref_b;\n    ref_b = temp;\n}\n\nint main() {\n    int a = 5;\n    int b = 10;\n    swap(a,b);\n    cout &lt;&lt; &quot;a: &quot; &lt;&lt; a &lt;&lt; &quot;, b: &quot; &lt;&lt; b &lt;&lt; endl; \/\/ 10,5\n    return 0;\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">By doing this, the original variable is passed as a parameter, and the swap happens successfully.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>int&amp; ref_a; \/\/ error<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">For your information, if you do not declare the variable to be referenced when declaring a reference variable, an error occurs.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>int a = 10;\nint&amp; ref_a = a;\nint b = 20;\nref_a = b;<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">Because a reference variable cannot be modified to refer to another variable, writing it this way does not change the referenced variable, but instead changes the value of a to 20.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Exception handling<\/h2>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">Actually, as I\u2019ve been learning C++, I\u2019ve come to realize that C# was a very convenient language. You probably know that you need `try`, `throw`, and `catch` to handle exceptions. However, in C++, you must explicitly write `throw` for exceptions to work.<\/p>\n<\/blockquote>\n\n\n\n<pre class=\"wp-block-code\"><code>try {\n    int[] arr = {1,2,3};\n    Console.WriteLine(arr[10]); \/\/ Exception is thrown automatically\n} catch (Exception e) {\n    Console.WriteLine(e.Message); \/\/ Handled in catch\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">In C#, even without explicitly writing a `throw` statement like this, the exception was automatically thrown at runtime\u2026 Thanks, C#\u2026. But that\u2019s not the case with our C++.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>try {\n    int a = 10, b = 0;\n    int c = a \/ b; \/\/ Division by zero (runtime error)\n    cout &lt;&lt; c &lt;&lt; endl;\n} catch (const char* msg) {\n    cout &lt;&lt; &quot;Exception occurred: &quot; &lt;&lt; msg &lt;&lt; endl;\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This C++ code does not trigger the catch block and causes the program to terminate abnormally. The reason is that without a throw, the exception cannot be handled.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>try {\n    int a = 10, b = 0;\n    if (b == 0) throw \"Cannot divide by 0!\";\n    int c = a \/ b;\n    cout &lt;&lt; c &lt;&lt; endl;\n} catch (const char* msg) {\n    cout &lt;&lt; &quot;Exception occurred: &quot; &lt;&lt; msg &lt;&lt; endl;\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">You need to handle exceptions using `throw` in areas where such errors might occur.<\/p>\n\n\n\n<pre class=\"wp-block-verse\">For detailed information on C++ syntax and standard libraries <a href=\"https:\/\/en.cppreference.com\/\" target=\"_blank\" rel=\"noreferrer noopener\">official cppreference documentation<\/a>It is helpful to refer to.<\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">Stack unwinding<\/h3>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">It is the process of \u201cunwinding\u201d the call stack when an exception occurs in C++, cleaning up the variables and objects of each function until the exception is handled.<\/p>\n<\/blockquote>\n\n\n\n<pre class=\"wp-block-code\"><code>void func3() { throw std::runtime_error(\"Exception occurred!\"); }\nvoid func2() { func3(); }\nvoid func1() { func2(); }\n\nint main() {\n    try {\n        func1();\n    } catch (std::exception&amp; e) {\n        std::cout &lt;&lt; e.what() &lt;&lt; std::endl;\n    }\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">When an exception occurs in func3, the stack unwinds in the order of func3() -&gt; func2() -&gt; func1() -&gt; main, and each function is cleaned up.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Omit exceptions<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>void safeFunction() noexcept {\n    \/\/ Code that does not throw exceptions\n    std::cout &lt;&lt; &quot;This function will not throw exceptions.&quot; &lt;&lt; std::endl;\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><code>noexcept<\/code> You can explicitly indicate that a specific function does not throw exceptions through keywords. This creates advantages in terms of optimization.<br>However, if an exception occurs, terminate() is called immediately and the program exits right away.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>void myTerminate() {\n    std::cerr &lt;&lt; &quot;Unhandled exception! Program will terminate.&quot; &lt;&lt; std::endl;\n    exit(-1); \/\/ Must terminate\n}\n\nint main() {\n    std::set_terminate(myTerminate);\n    throw 1; \/\/ Unhandled exception\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\"><code>set_terminate<\/code>is the function that replaces the default termination behavior when an \u201cunhandled exception\u201d occurs in C++ and causes the program to terminate.<br>Therefore, set_terminate must always include logic to terminate the program.<br>Exit codes include abort(), exit(), quick_exit(), etc.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Template<\/h2>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">A function template is a syntax that generalizes a data type into a single form\u2014a concept similar to generics in C#.<\/p>\n<\/blockquote>\n\n\n\n<pre class=\"wp-block-code\"><code>template\nT Add (T a1, T a2) {\n    return a1 + a2;\n}\n\nint main() {\n    int    x = Add(1, 2);        \/\/ T is automatically inferred as int\n    float  y = Add(1.5f, 2.5f);  \/\/ T = float\n    double z = Add(1.2, 3.4);    \/\/ T = double\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This allows you to cover multiple data types at the same time.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">Explicit call<\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li>This is a method of explicitly writing the type instead of letting the compiler automatically infer it.<\/li>\n<\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code>template\nT Add(T a, T b) { return a + b; }\n\n\/\/ 1) Type inference (implicit call)\nint    a = Add(1, 2);          \/\/ T = int\ndouble b = Add(1.2, 3.4);      \/\/ T = double\n\n\/\/ 2) Explicit invocation\nint    c = Add(1, 2);     \/\/ Explicitly specifies T = int\nauto   d = Add(1, 2);  \/\/ Although the arguments are int, T is inferred as double<\/code><\/pre>\n\n\n\n<h3 class=\"wp-block-heading\">template specialization<\/h3>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">Template specialization means keeping the primary template as is while creating a different version specifically for a particular type.<\/p>\n<\/blockquote>\n\n\n\n<pre class=\"wp-block-code\"><code>\/\/ 1. Basic function template\ntemplate\nvoid LogDamage(T dmg) {\n    std::cout &lt;&lt; &quot;[DMG] &quot; &lt;&lt; dmg &lt;&lt; &quot;\\n&quot;;\n}\n\n\/\/ 2. Specialization for `int`\ntemplate &lt;&gt;\nvoid LogDamage(int dmg) {\n    std::cout &lt;&lt; &quot;[DMG:int] &quot; &lt;&lt; dmg &lt;&lt; &quot; (critical)\\n&quot;;\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">You can just separate the data types you want to specialize like this.<br>When specialization is performed, the specialized part is executed instead of the base template.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>public static class Logger\n{\n    public static void Log(T v)\n    {\n        Console.WriteLine($&quot;[GENERIC] {v}&quot;);\n    }\n\n    \/\/ Overload for int only\n    public static void Log(int v)\n    {\n        Console.WriteLine($&quot;[INT] {v} (critical)&quot;);\n    }\n}<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">You can also specialize generics in this way in C#.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">class template<\/h3>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p class=\"wp-block-paragraph\">Creating a universal class with a template makes it a class template. When a class is made into a template, its member variables and member functions are handled as templates.<br>(Does not necessarily have to be a template)<\/p>\n<\/blockquote>\n\n\n\n<pre class=\"wp-block-code\"><code>template \nclass PlayerStat {\npublic:\n    T hp;                  \/\/ Template type\n    int level;             \/\/ Regular type\n    static int onlineCnt;  \/\/ Can also be static\n\n    void AddHp(T v) {      \/\/ Member function using a template type\n        hp += v;\n    }\n\n    void LevelUp() {       \/\/ Regular member function unrelated to templates\n        level++;\n    }\n};\n\ntemplate\nint PlayerStat::onlineCnt = 0;;<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">This is how the class itself is templated.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>PlayerStat    p1;  \/\/ T = int\nPlayerStat  p2;  \/\/ T = float<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">And when first declaring a class template, the data type must also be specified together.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\">\ud074\ub798\uc2a4 \ud15c\ud50c\ub9bf \ubd80\ubd84 \ud2b9\uc218\ud654<\/h3>\n\n\n\n<pre class=\"wp-block-code\"><code>template &lt;typename T1, typename T2&gt;\nclass Pair {\npublic:\n    T1 first;\n    T2 second;\n};\n\n\/\/ T1 = int, T2\ub294 \uc544\ubb34 \ud0c0\uc785(T) \uac00\ub2a5\ntemplate &lt;typename T&gt;\nclass Pair&lt;int, T&gt; {\npublic:\n    int first;\n    T   second;\n\n    void Print() {\n        std::cout &lt;&lt; \"&#91;int, T] \" &lt;&lt; first &lt;&lt; \", \" &lt;&lt; second &lt;&lt; \"\\n\";\n    }\n};<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\uc774\ub807\uac8c \ud2b9\uc815 \ubd80\ubd84\ub9cc \ud2b9\uc218\ud654\ub97c \uc9c4\ud589\ud560 \uc218 \uc788\ub2e4.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>\/\/ \uae30\ubcf8: \uc5b4\ub5a4 \ud0c0\uc785\uc774\ub4e0 \uadf8\ub0e5 \ubcf5\uc0ac\ud574\uc11c \ud328\ud0b7 \uc0dd\uc131\ntemplate &lt;typename T&gt;\nclass PacketWriter {\npublic:\n    void Write(const T&amp; data) {\n        \/\/ data\ub97c \uadf8\ub300\ub85c \uc9c1\ub82c\ud654\n    }\n};\n\n\/\/ \ubd80\ubd84 \ud2b9\uc218\ud654: \ud3ec\uc778\ud130 \ud0c0\uc785\ub9cc \ud2b9\ubcc4 \ucc98\ub9ac (\ub110 \uccb4\ud06c \ub4f1)\ntemplate &lt;typename T&gt;\nclass PacketWriter&lt;T*&gt; {\npublic:\n    void Write(T* data) {\n        if (data == nullptr) {\n            \/\/ \ub110 \ud3ec\uc778\ud130\uba74 '\uc5c6\uc74c' \ud328\ud0b7\n        } else {\n            \/\/ *data\ub97c \uc9c1\ub82c\ud654\ud574\uc11c TCP\ub85c \uc804\uc1a1\n        }\n    }\n};<\/code><\/pre>\n\n\n\n<p class=\"wp-block-paragraph\">\ucc38\uace0\ub85c \ud3ec\uc778\ud130 \ud0c0\uc785\uc73c\ub85c \ud2b9\uc218\ud654\ub97c \uc9c4\ud589\ud560 \uc218\ub3c4 \uc788\ub2e4.<\/p>","protected":false},"excerpt":{"rendered":"<p>\uc11c\ub860 c++ basic\uc744 \uacf5\ubd80\ud558\uae30 \uc704\ud574\uc11c\ub294 \ub2e4\ub978 \uc5b8\uc5b4\ub4e4\uacfc\uc758 \uae30\ubcf8\uc801\uc778 \ucc28\uc774\ub97c \uc774\ud574\ud574\uc57c \ud55c\ub2e4. \uadf8 \ucc28\uc774\ub294 \ubc14\ub85c \uba54\ubaa8\ub9ac \uad00\ub9ac\uc640 \uc6d0\ubcf8 \ubcc0\uc218\ub97c \ub2e4\ub8e8\uace0 \uc8fc\uc18c\ub97c \ub2e4\ub8ec\ub2e4\ub294 \uc810\uc5d0 \uc788\ub2e4. \uc6b0\ub9ac\ub294 \uc55e\uc73c\ub85c C++\uc758 \uc774\ub7ec\ud55c \uac1c\ub150\ub4e4\uc5d0 \ub300\ud574\uc11c \ud559\uc2b5\ud574\ubcfc \uac83\uc774\ub2e4, C++ Basics: \uc815\uc801 \ud560\ub2f9\uacfc \ub3d9\uc801 \ud560\ub2f9\uc758 \ucc28\uc774 \ub9e4\uc6b0 \uae30\ubcf8\uc801\uc778 \uac1c\ub150\uc774\ub77c \ubaa8\ub974\uba74 \uc548\ub418\uc9c0\ub9cc \uadf8\ub798\ub3c4 \ud5f7\uac08\ub9b4 \uc218 \uc788\ub294 \ubd80\ubd84\uc774\ub77c \uc815\ub9ac\ub97c \ud574\ubcf4\uaca0\ub2e4. \uc815\uc801\ud560\ub2f9\uacfc \ub3d9\uc801\ud560\ub2f9\uc740 \ucef4\ud30c\uc77c\uacfc \uad00\ub828\uc774 \uc788\ub294\ub370, &#8230; <a title=\"[C++ Basic] Reference, Template, Allocate\" class=\"read-more\" href=\"https:\/\/corpusgame.com\/en\/c-basic-reference-template-allocate\/\" aria-label=\"More on [C++ Basic] Reference, Template, Allocate\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":17,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[6,5,4],"class_list":["post-11","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-cpp-basic-guide","tag-allocate","tag-c-basic","tag-template"],"_links":{"self":[{"href":"https:\/\/corpusgame.com\/en\/wp-json\/wp\/v2\/posts\/11","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/corpusgame.com\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/corpusgame.com\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/corpusgame.com\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/corpusgame.com\/en\/wp-json\/wp\/v2\/comments?post=11"}],"version-history":[{"count":4,"href":"https:\/\/corpusgame.com\/en\/wp-json\/wp\/v2\/posts\/11\/revisions"}],"predecessor-version":[{"id":18,"href":"https:\/\/corpusgame.com\/en\/wp-json\/wp\/v2\/posts\/11\/revisions\/18"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/corpusgame.com\/en\/wp-json\/wp\/v2\/media\/17"}],"wp:attachment":[{"href":"https:\/\/corpusgame.com\/en\/wp-json\/wp\/v2\/media?parent=11"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/corpusgame.com\/en\/wp-json\/wp\/v2\/categories?post=11"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/corpusgame.com\/en\/wp-json\/wp\/v2\/tags?post=11"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}