본문 바로가기
728x90
반응형

전체 글134

[C] 11. C언어의 -고급 주제(기타)- C 언어 학습: 고급 주제C 언어의 기본을 익힌 후에는 고급 주제를 통해 더욱 깊이 있는 프로그래밍 기술을 습득할 수 있습니다. 이번 글에서는 전처리기 지시자, 라이브러리와 모듈화, 네트워킹 기초(소켓 프로그래밍), 다중 스레딩(pthread)에 대해 알아보겠습니다.1. 전처리기 지시자 (#define, #include, #if 등)전처리기 지시자는 컴파일러가 소스 코드를 컴파일하기 전에 처리해야 할 명령을 지정합니다. 주요 전처리기 지시자는 다음과 같습니다:#define : 매크로를 정의합니다.[c]#define PI 3.14159 #include : 다른 파일을 포함합니다.[c]#include #include "myheader.h" #if, #elif, #else, #endif : 조건부 컴파일을 수.. 2024. 6. 14.
[C] 10. C언어의 -메모리 관리(기타)- C 언어 학습: 메모리 관리C 언어에서 메모리 관리는 매우 중요한 주제입니다. 프로그램이 실행되는 동안 필요한 메모리를 동적으로 할당하고, 더 이상 필요하지 않을 때 해제하는 것이 효율적인 메모리 사용의 핵심입니다. 이번 글에서는 동적 메모리 할당과 메모리 누수 및 디버깅에 대해 알아보겠습니다.1. 동적 메모리 할당 (malloc, calloc, realloc, free)동적 메모리 할당은 프로그램 실행 중에 필요한 메모리를 동적으로 할당하는 방법입니다. C 언어에서는 이를 위해 malloc, calloc, realloc, free 함수를 제공합니다.malloc : 지정된 크기의 메모리를 할당하고, 포인터를 반환합니다.[c]void *malloc(size_t size); calloc : 지정된 수의 요소.. 2024. 6. 14.
[LOL] 챔피언(가렌) AI 생성 이미지 프롬프트(prompt):A stunning desktop wallpaper featuring Garen from League of Legends. Garen is depicted as a powerful warrior in detailed, ornate armor with a massive sword. He stands heroically on a battlefield, with dynamic lighting and a stormy, ominous sky in the background. His cape flows dramatically in the wind, emphasizing the intense and powerful atmosphere. The image is designed with a wid.. 2024. 6. 13.
[LOL] 챔피언(아트록스) AI 생성 이미지 프롬프트(prompt):A stunning desktop wallpaper featuring Aatrox from League of Legends. Aatrox is depicted as a fearsome, dark warrior with demonic wings, wielding a massive, red-bladed sword. He stands on a battlefield, surrounded by a dark and chaotic environment, with dramatic lighting highlighting his menacing presence. The background features a stormy sky with flashes of lightning. The image is .. 2024. 6. 13.
[LOL] 챔피언(판테온) AI 생성 이미지 프롬프트(prompt):A stunning desktop wallpaper featuring Pantheon from League of Legends. Pantheon is depicted as a powerful warrior in detailed, ornate Greek-style armor, with a Corinthian helmet with a tall plume, a large round shield, and a long spear. He stands heroically on a dramatic battlefield, with dynamic lighting and a stormy, ominous sky in the background. His cape flows dramatically in t.. 2024. 6. 13.
[C] 9. C언어의 -파일 입출력(기타)- C 언어 학습: 파일 입출력C 언어에서 파일 입출력은 데이터를 파일에 저장하거나 파일로부터 데이터를 읽어오는 중요한 기능입니다. 이번 글에서는 파일 개방과 닫기, 파일 읽기와 쓰기, 파일 위치 조정에 대해 알아보겠습니다.1. 파일 개방과 닫기 (fopen, fclose)파일을 사용하기 위해서는 먼저 파일을 열어야 합니다. 이를 위해 fopen 함수를 사용하며, 파일 사용이 끝나면 fclose 함수를 사용하여 파일을 닫습니다.fopen : 파일을 열고 파일 포인터를 반환합니다.[c]FILE *fopen(const char *filename, const char *mode);  filename : 열 파일의 이름mode : 파일을 여는 모드 ("r" 읽기, "w" 쓰기, "a" 추가 등) fclose : 파.. 2024. 6. 13.
728x90
반응형