Skip to Content
밑바닥부터 시작하는 데이터 과학 데이터 분석을 위한 파이썬 프로그래밍과 수학·통계 기초
book

밑바닥부터 시작하는 데이터 과학 데이터 분석을 위한 파이썬 프로그래밍과 수학·통계 기초

by Joel Grus, Hangyeol Kim, Seongju Ha, Eunjung Park
May 2022
Beginner to intermediate
448 pages
13h 7m
Korean
Insight
Content preview from 밑바닥부터 시작하는 데이터 과학 데이터 분석을 위한 파이썬 프로그래밍과 수학·통계 기초
Data Science
32
󻱴󽴔󽴔󼟛󻱃󻠻󽴔󻙜󻘀󽴔󺃤󻵛
나머지 거의 모든 것은 참(
True
)을 의미한다. 이를 통해 리스트, 문자열, 딕셔너
리 등이 비어 있는지 쉽게 확인할 수 있다. 하지만 예상치 못한 오류가 발생하기
도 한다.
s = some
_
function
_
that
_
returns
_
a
_
string()
if s:
first
_
char = s[0]
else:
first
_
char = ""
위 코드는 다음과 같이 더욱 간단하게 표현할 수 있다.
first
_
char = s and s[0]
and
는 첫 번째 값이 참이면 두 번째 값을 반환해 주고, 첫 번째 값이 거짓이면 첫
번째 값을 반환해 준다. 만약
x
가 숫자거나
None
이라면
safe
_
x = x or 0
위의 값은 항상 숫자일 것이다. 하지만
safe
_
x = x if x is not None else 0
이렇게 표현하는 것이 읽기 더 편할 것이다.
파이썬에는 리스트의 모든 항목이 참이라면
True
를 반환해 주는
all
함수와
적어도 하나의 항목이 참이라면
True
를 반환해 주는
any
함수가 있다.
all([True, 1, {3}]) # True
all([True, 1, {}]) # False, {}
거짓을
의미하기
때문에
any([True, 1, {}]) # True
all([]) # True,
거짓인
항목이
없기
때문에
any([]) ...
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

안드로이드 멀티스레딩: 비동기 메커니즘으로 날렵하고 안정적인 앱 만들기

안드로이드 멀티스레딩: 비동기 메커니즘으로 날렵하고 안정적인 앱 만들기

한대희, 안데르스 예란손

Publisher Resources

ISBN: 9788966262571