- 浏览: 45614 次
- 性别:
- 来自: 南京
文章分类
最新评论
Non-terminating decimal expansion; no exact representable decimal result
- 博客分类:
- java基础
异常信息:Non-terminating decimal expansion; no exact representable decimal result
通过BigDecimal的divide方法进行除法时当不整除,出现无限循环小数时,就会抛异常:java.lang.ArithmeticException: Non-terminating decimal expansion; no exact representable decimal result.
解决的办法就是给divide方法设置精确的小数点,如:divide(xxxxx,2)。
通过BigDecimal的divide方法进行除法时当不整除,出现无限循环小数时,就会抛异常:java.lang.ArithmeticException: Non-terminating decimal expansion; no exact representable decimal result.
解决的办法就是给divide方法设置精确的小数点,如:divide(xxxxx,2)。
发表评论
-
java中静态代码块的用法 static用法详解
2013-06-18 17:14 767(一)java 静态代码块 ... -
java中的native关键字
2013-06-18 14:35 856JNI是Java Native Interface的 缩写。从 ... -
Java fina 方法和类
2013-06-18 14:34 826final方法 将方法声明为final那有两个原因: ... -
Java transient关键字
2013-06-18 14:33 790java关键字Transient 转自http:/ ... -
Java Assert使用
2013-06-14 14:01 1256主要总结一下在eclipse中如何使用断言。 (一)首先明确 ... -
Java中接口的使用方法简介
2013-06-14 13:48 2301接口申明必须有interface ... -
堆和栈的区别
2013-06-14 12:50 754堆和栈的区别 栈与堆 ... -
HashSet详解:不能重复(对象的哈希代码一样),无序
2012-09-27 16:05 1209HashSet中不允许有重复的元素。例如: Set hash ... -
java i++和++i
2012-08-28 10:30 675//i++是在一个先使用后加1,即先使用i的值,后让i+1 ... -
java 可变长参数
2012-08-15 17:08 864有时候,我们传入到方法的参数的个数是不固定的,为了解决这个问题 ... -
字符编码问题
2012-07-26 16:14 720String newStr = new String(oldS ... -
java发邮件包commons-email-1.0.jar
2012-07-26 16:11 815java发邮件的包commons-email-1.0.jar -
获取图片的宽和高 java
2012-07-26 16:09 919有两种要考虑的情况: 一种是:(图片在本地可以预览到),方法如 ... -
java 值传递和引用传递
2012-07-26 14:52 1001class Demo{ private static i ... -
java面试题解惑 之 多线程(转)
2012-07-20 15:25 9651,多线程 线程或者说 ... -
java定时器应用举例
2012-07-20 14:32 735package myThread; import jav ... -
Java中的IO整理完整版(二)
2012-07-12 16:41 615BufferedReader的小例子 注意: Buffere ... -
Java中的IO整理完整版(一)
2012-07-12 14:22 735【案例1】创建一个新文件 import java.io.*; ...
相关推荐
[r4118]fix non-ascii characters in ACPI tables headers;[r4119]new csr settings, by PMheart;[r4120]consider more intel cpu family. update some information.;[r4121]align SETTING_DATA;[r4122]OemID ...
DTE英文全称Data Terminal Equipment,DCE英文全称Data Circuit-terminating Equipment.
AM-Asterisk PBX GUI配置/管理系统。 AM提供了用于创建Asterisk配置(.conf)文件HTML界面。 它还允许您远程管理和监视集团电话。
py>> > show ( '0.25' )s exp significants0 01111101 00000000000000000000000 = 0.25+ - 2>> > show ( '0.3' ) # example of a non-terminating expansions exp significants0 01111101 00110011001100110011010 ...
-Terminating app main thread with osThreadExito to avoid endless loop Added board support: -NUCLEO-F429ZI board -NUCLEO-F746ZG board Added debugProbe attribute to board description.
这个中间设备就是数据电路端设备 DC(DataCircuit-terminating Equipment)。DCE 的作用就是在 DTE 和传输线路之间提供信号变换和编码的功能,并且负责建立、保持和释放数据链路的连接。DTE 可以是一台计算机或一个...
oracle 11g rac terminating the instance due to error 481 Doc ID 1383737.1
fix crash ---- Terminating app due to uncaught exception NSInvalidArgumentException , reason: [AVCaptureMetadataOutput setMetadataObjectTypes:] unsupported type found. Use ...
Chapter One Chapter One - Data Representation 1.0 - Chapter Overview 1.1 - Numbering Systems 1.1.1 - A Review of the Decimal System 1.1.2 - The Binary Numbering System 1.1.3 - ...
Removed non-existent include path. CMSIS Flash Algorithm: Corrected STM32F42xxx_43xxx_OPT Algorithm. CMSIS SVD: Updated STM32F42*.svd, STM32F43*.svd files. CMSIS-Driver: I2C: Corrected 2 byte ...
Removed non-existent include path. CMSIS Flash Algorithm: Corrected STM32F42xxx_43xxx_OPT Algorithm. CMSIS SVD: Updated STM32F42*.svd, STM32F43*.svd files. CMSIS-Driver: I2C: Corrected 2 byte ...
Terminating app_main thread with osThreadExit() to avoid endless loop. Updated RTX configuration (CMSIS 5.8.0). Updated template based files (MDK-Middleware 7.13.0). Configured MDK projects to use Arm...
Terminating app due to uncaught exception 'NSGenericException', reason: 'UIPopoverPresentationController () should have a non-nil sourceView or barButtonItem set before the presentation occurs.' ...
Decimal and Binary Systems. ASCII Code. Negative Integers and Two's Complement. Hexadecimal Numbers. BCD Numbers. Little Endian Format and Intel Notation. Logic Gates. Basic Logical ...
Warning: --C99 is no longer enforced via the device description. Enable 'C99 Mode' in 'Options for Target' dialog's 'C/C++' tab. Updated Pack to include subset of STM32Cube_FW_F4 Firmware Package ...
ABAQUS模拟时遇到的问题及解决
consideration of the problems of initiating and terminating such a connection , it has been decided to reserve link 0 for communication between HOST operating systems. The remaining 31 links are ...
Formatting Line Length Non-ASCII Characters Spaces vs. Tabs Function Declarations and Definitions Function Calls Conditionals Loops and Switch Statements Pointer and Reference Expressions Boolean ...
6.8.3 Non-standard MNP Solutions 341 6.9 Control of IP Multimedia Calls 342 6.9.1 Rationale of CAMEL Control of IMS 345 6.9.2 The IM-SSF 346 6.9.3 Registration 347 6.9.4 IMS Call Control 348 6.9.5 ...
Warning: --C99 is no longer enforced via the device description. Enable 'C99 Mode' in 'Options for Target' dialog's 'C/C++' tab. Updated Pack to include subset of STM32Cube_FW_F4 Firmware Package ...