Posts

C Language - The Grammar of a Programming Language

Image
1. Language Grammar Human language has a wide variety of grammar , and learning it requires a great deal of time. You need to learn many grammatical elements such as nouns, verbs, tense, and word order. A programming language is a language with the clear purpose of instructing a computer what to do and how to do it. Even with a relatively small number of grammatical elements, it is possible to express meaning and execute actions. Unlike human language, a programming language can be used immediately once you understand a few core grammar rules . 2. C Language Grammar A programming language consists of the following five elements. Variables - store values. Operations - calculate values. Statements - execute content. Control - change the order of execution. Functions - group multiple statements into one. Understanding just these five grammar elements is enough to understand the basic structure of a program. 2.1. Variables A variable is a memory space that store...

C Language – Starting with “Hello, World!”

Image
1. Installing the C Compiler The most widely used compiler for developing C programs in a Linux environment is GCC (GNU Compiler Collection). While it can be installed individually, it is more efficient to install it via the build-essential package, which includes a collection of essential development tools. $ sudo apt update $ sudo apt install -y build-essential $ gcc --version gcc ... $ make --version GNU Make ... GCC (GNU Compiler Collection) : The standard C compiler in Linux environments. build-essential : A package that installs essential development tools at once, including GCC, g++ (C++ compiler), make (build automation tool), and libc6-dev (standard libraries and headers). 2. The First Program Since the example of printing “Hello, world!” was introduced in the 1978 book The C Programming Language [1] , this phrase has been widely used as the most basic introductory example in programming textbooks across almost all programming la...

Vibe Coding - Four Ways to Structure Prompts

Image
1. Custom Instructions The first step to using AI effectively is to ‘ write good prompts ’. The quality of an AI model’s responses is heavily influenced by prompt design. Custom Instructions is a feature that lets you predefine the default instructions AI should always refer to when responding. In other words, it is a setting that continuously applies recurring instructions such as the user’s language and work style, making it a personalization feature . This makes it possible to maintain a consistent style without repeating the same prompt every time. 1.1. GitHub Copilot In GitHub Copilot, instructions that are automatically loaded for a project are written in the file at the following path. .github/copilot-instructions.md 1.2. Gemini Code Assist In Gemini Code Assist, project instructions are stored using the following filename. GEMINI.md 1.3. Example The purpose of Custom Instructions is not to make prompts better, but to predefine requests that are used repeatedly . ...

Vibe Coding - Creating Code with Natural Language

Image
1. Vibe Coding The term “Vibe Coding” first appeared in a post by Andrej Karpathy on X (Twitter) in February 2025. He is a co-founder of OpenAI and previously served as the Head of AI at Tesla. "There's a new kind of coding I call vibe coding, where you fully give in to the vibes, embrace exponentials, and forget that the code even exists." [Source] X - Andrej Karpathy The core idea of “Vibe Coding” is a development approach where instead of manually writing code, developers describe requirements in natural language and let AI generate the code . Just like creating music by following rhythm, coding is performed by riding the “vibe,” progressing based on flow and atmosphere . In summary, Vibe Coding is an AI-driven development paradigm where you build by requesting tasks from AI , focusing more on outcomes and flow rather than the code itself. 2. Code Assistant A Code Assistant is an AI tool that generates or modifies code based on natural ...

How an Executable File Operates

Image
1. Assembly The machine language understood by the CPU is binary code . Assembly expresses machine language in human-readable mnemonic instructions. Therefore, the programming language most similar to machine code is Assembly . To understand how machine code is executed, we will examine a simple Assembly program. The following Assembly code performs the operation of printing the result of "2 + 3". ; Ubuntu 24.04 x86-64 (NASM, ELF64) section .data msg db "result: " msg_len equ $ - msg newline db 0x0a section .bss buf resb 1 section .text global _start _start: mov al, 2 add al, 3 mov bl, al mov rax, 1 mov rdi, 1 mov rsi, msg mov rdx, msg_len syscall mov al, bl add al, '0' mov [buf], al mov rax, 1 mov rdi, 1 mov rsi, buf mov rdx, 1 syscall mov rax, 1 mov rdi, 1...

Computer Operations Explained with Gate Circuits

Image
1. Computer The film "Hidden Figures (2016)" tells the true story of the African American women mathematicians whose work helped make NASA’s space program successful. In this film, the women mathematicians hold the job title " computer ." A computer is a machine that performs calculations. But how does it actually carry them out? A computer performs logical and arithmetic operations using " Gate Circuit "s made up of numerous transistors. 2. Operation 2.1. Basic When current flows ( ON ), the light bulb turns on, and when it does not flow ( OFF ), it turns off. 👉  circuitjs-basic ※ In actual physics, the electrons that create electric current move from (–) to (+) . However, before electrons were known to exist, Franklin defined electric charge as moving from (+) to (–), and that convention remained in use for a long time. As a result, even today, the direction of current is conventionally described as flowing from (+) to ...