Skip to main content

All Questions

1 vote
1 answer
1k views

Is new object creation necessary with BigDecimal?

Problem description: I am running performance test of calculation of PI number with primitives and with BigDecimal class. Calculation of PI with primitives is around 5-6 times faster than the same ...
DevDio's user avatar
  • 257
0 votes
0 answers
132 views

Best datastructure to use

I am using Amazon's dynamodb nosql database and as a result I need to think of some ways to do certain operations to fit into their limits (e.g 4k item limit, can't combine small items into the same ...
user2924127's user avatar
6 votes
4 answers
34k views

Most Efficient way to Compute the sum of divisors of N (1 ≤ N ≤ 1 000 000 000)

I want to write a code which computes the sum of divisors of a number N(1 ≤ N ≤ 1 000 000 000), excluding the number itself. However, I need an efficient way to do it. It suppose to print the answer ...
Jon Snow's user avatar