Common 부동소수점 연산에 관한 정리

황제낙엽 2018.03.26 17:28 조회 수 : 1212

sitelink1 http://floating-point-gui.de/ 
sitelink2  
sitelink3  
sitelink4  
sitelink5  
extra_vars6  

What Every Programmer Should Know About Floating-Point Arithmetic

or

Why don’t my numbers add up?

So you’ve written some absurdly simple code, say for example:

	0.1 + 0.2

and got a really unexpected result:

	0.30000000000000004

Maybe you asked for help on some forum and got pointed to a long article with lots of formulas that didn’t seem to help with your problem.

Well, this site is here to:

  • Explain concisely why you get that unexpected result
  • Tell you how to deal with this problem
  • If you’re interested, provide in-depth explanations of why floating-point numbers have to work like that and what other problems can arise

You should look at the Basic Answers first - but don’t stop there!

번호 제목 글쓴이 날짜 조회 수
공지 Software Development Trend (with Java) 황제낙엽 2024.01.19 896
112 자연어 처리 Natural Language Processing 황제낙엽 2019.03.06 184
111 NUI(Natural User Interface) / NUX(Natural User eXperience) 황제낙엽 2019.03.03 286
110 지수(과학적 표기법, "E") 서식 지정자 (1) 황제낙엽 2018.11.03 210
109 AI의 연도별 역사 황제낙엽 2018.11.03 389
108 마이크로소프트 MSDN의 이해 file 황제낙엽 2018.09.18 176
107 효율적인 양식 디자인: 구조, 입력, 레이블 및 액션 file 황제낙엽 2018.05.08 162
106 마이크로소프트 제품의 라이선스 - 패키지(FPP)와 볼륨라이선스(Volume License) 황제낙엽 2018.04.12 229
105 효과적인 모바일 애니메이션 응용예 file 황제낙엽 2018.03.30 2277
104 notepad2 에서 문서내의 일부 문자열의 byte 크기 알아내기 file 황제낙엽 2018.03.29 2034
» 부동소수점 연산에 관한 정리 황제낙엽 2018.03.26 1212
102 버튼 디자인의 고찰 (12가지 팁) file 황제낙엽 2018.02.07 179
101 스크래치는 왜 이름이 스크래치 인가? file 황제낙엽 2018.02.01 203
100 윈도우10 FPP,OEM,DSP,ESD 라이선스 file 황제낙엽 2017.10.24 423
99 Atom(에디터) file 황제낙엽 2017.08.31 462
98 엑셀(excel)에서 16진수 -> 10진수 변환 file 황제낙엽 2017.08.29 4478
97 어린이, 청소년용 프로그램 입문 황제낙엽 2017.05.03 215
96 마이크로소프트로부터 기술지원을 받기 위한 Access ID 발급 방법 황제낙엽 2016.12.05 174
95 컴퓨터는 음수를 2의 보수법으로 표현한다 file 황제낙엽 2016.10.24 901
94 변수를 unsigned int형 선언 0xffffffff 할당 결과가 -1이 되는 이유는? 황제낙엽 2016.10.24 541
93 0xFFFFFFFF의 값은 왜 -1인가? 황제낙엽 2016.10.24 403