Skip to Content
우아한 C언어 코딩 패턴
book

우아한 C언어 코딩 패턴

by Christoper Preschem, 정기훈(Jung Ki Hun)
April 2024
Beginner to intermediate
364 pages
7h 2m
Korean
Insight
Content preview from 우아한 C언어 코딩 패턴
C
325
󼟷󼘃󽴔󻝳󼙯󺹻
return USER
_
ALREADY
_
EXISTS;
}
for(int i
=
0; i<MAX
_
USERS; i++)
{
if(strcmp(userList[i].name, "")
==
0)
{
strcpy(userList[i].name, username);
strcpy(userList[i].pwd, pwd);
return USER
_
SUCCESSFULLY
_
ADDED;
}
}
return USER
_
ADMINISTRATION
_
FULL;
}
지금까지 구현한 코드 조각들을 사용하여 사용자 관리 목록을 사용자로 채우
고 제공된 비밀번호가 해당 사용자의 것과 일치하는지 확인할 수 있다.
󻃧󻇄
다음으로 반복자를 구현하여 모든 사용자 이름을 읽을 수 있는 몇 가지 기능을
제공한다. 호출자가 인덱스로
userList
배열에 접근할 수 있도록 하는 인터페
이스를 제공하고 싶을 수도 있지만, 기본 자료 구조가 변경되거나(예: 연결 리
스트) 특정 호출자가 배열을 수정하는 동안 또 다른 호출자가 배열에 접근하려
는 경우 문제가 발생할 수 있다.
이 문제를 해결하는 반복자 인터페이스를 호출자에게 제공하기 위해서는
핸들을 사용하여 호출자에 기본 자료 구조를 숨기는 커서 반복자를 구현하면
된다.
󼟷󼘃󽴔󻱃󺹓 󻭣󻩌
󼎳󻗫
󻃧󻇄󻱟
󺋿󻇇󽴔󻱟󺶛󽴔󺈻󻴿󻰧󽴔󻭣󻙛󺹋󽴔󺃏󺹻󼕳󺝣󽴔󻃧󻇄󻱟󽴔󻱇󻝳󼘃󻝳󺹋󽴔󺺛󺦯󺞳 ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

AI를 위한 필수 수학

AI를 위한 필수 수학

할라 넬슨
파이썬으로 살펴보는 아키텍처 패턴

파이썬으로 살펴보는 아키텍처 패턴

오현석, 해리 퍼시벌, 밥 그레고리
개발 7년차, 매니저 1일차

개발 7년차, 매니저 1일차

권원상, 한민주, 카미유 푸르니에
클라우드 네이티브 애플리케이션 디자인 패턴

클라우드 네이티브 애플리케이션 디자인 패턴

카순 인드라시리, 스리스칸다라자 수호티얀

Publisher Resources

ISBN: 9788966264742