arithmeticexception Questions
6
Solved
After a series of calculations in my code, I have a BigDecimal with value 0.01954
I then need to multiply this BigDecimal by 100 and I wish the calculated value to be 1.95
I do not wish to perfor...
Blunk asked 17/6, 2014 at 20:36
9
Solved
Why does the following code raise the exception shown below?
BigDecimal a = new BigDecimal("1.6");
BigDecimal b = new BigDecimal("9.2");
a.divide(b) // results in the following exception.
Except...
Partnership asked 4/1, 2011 at 6:34
8
Solved
Why doesn't this code throw an ArithmeticException? Take a look:
public class NewClass {
public static void main(String[] args) {
// TODO code application logic here
double tab[] = {1.2, 3.4, 0...
Collodion asked 3/1, 2013 at 11:25
3
I went across some sort of limitation in ASP.NET.
I reduced the problem into a sample project in ASP.NET MVC Project (created with Visual Studio 2010 and .NET 4) and the problem still occurs:
In a...
Rezzani asked 9/3, 2014 at 22:41
2
Solved
Why some numbers are defined as not a number(NaN) in floating point arithmetic?
(Although they can be represented by IEEE format and indeed are real numbers)
Diantha asked 9/11, 2018 at 10:0
3
I've been getting a Floating point exception (core dumped) error in my C++ program, and gdb shows that the problem is on a line that performs modulo division:
Program received signal SIGFPE, Arith...
Mcgann asked 31/12, 2012 at 5:44
3
Solved
I am using SQL Server 2008 R2 and I have an INT column where the data inserted never surpasses the max INT, but I have a query which uses the SUM function which when executed surpasses the max INT ...
Sex asked 27/11, 2011 at 21:42
1
I am trying to implement the RSA-Algorithm in an Android Application. I am using the java.math.BigInteger.modPow() function for the en-/decryption which works fine for my Computer (Windows and Xubu...
Peskoff asked 21/10, 2014 at 14:28
6
Solved
The following statement throws java.lang.ArithmeticException: / by zero as obvious.
System.out.println(0/0);
because the literal 0 is considered to be an int literal and divide by zero is not allo...
Vocation asked 18/10, 2012 at 12:5
1
© 2022 - 2025 — McMap. All rights reserved.