print(round(-2.5))의 결과는?
답은 -2 이다. 파이썬 3.0부터는 숫자 반올림 방법이 banker's rounding이라는 방법을 사용한다. https://docs.python.org/3/whatsnew/3.0.html What’s New In Python 3.0 Author, Guido van Rossum,. This article explains the new features in Python 3.0, compared to 2.6. Python 3.0, also known as “Python 3000” or “Py3K”, is the first ever intentionally backwards incomp... docs.python.org banker's rounding은 요약하면 가까운 수로 맞추되 정확히 절반인 경우 짝수로..
language/python
2023. 8. 13. 11:48
최근에 올라온 글
최근에 달린 댓글
- Total
- Today
- Yesterday
링크
TAG
- pessimisticlock
- Python
- Redis
- jmeter토큰
- 대규모더미데이터
- 토큰
- jmeter로그인
- Redisson
- index
- jmeter세션
- EC2
- Lock
- Spring
- jwt
- 자바
- jmeter테스트
- jmeter쿠키
- Java
- jmeter시나리오
- 항해
- bankersRounding
- 스프링faker
- 부하테스트시나리오
- CorrectnessAndTheLoopInvariant
- hackerrank
- 프로그래머스
- jmeter부하테스트
- 인덱스
- CheckedException
- 동적크롤링
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
글 보관함