Saturday, June 29, 2013

HumanAddition - Addition calculator using human method


==[Update 1]==
Performance Improvements
 - Same test as before now takes less than 1 second (~ 700ms)
 - Changed the logic up a little to remedy the "different number lengths taking longer" issue, now if
   you add a large number with a small one it will be faster than adding 2 same size numbers.
Non-Number Checks
 - Removes all characters that are not valid digits
Progress Bar/Report
 - Progress loading bar and percentage, but it bugs out on very high numbers like one with 50,000,000 digits

== Download ==
http://www.mediafire.com/download/yz7rjcx3b6k6bmp/HumanAddition.exe

== Code ==
This probably isn't perfect, anyone wanting to make changes are free to, and submit them if you want in to comments.
==Log=
Welp I made another possibly useless simple program lol. This program is a single function calculator in that it only does addition. The purpose of this calculator though is adding two large numbers and presenting every digit. It does this by utilizing how we were taught addition in school, add two numbers starting from the right, if there is a carry, add in the carry. This calculator can be considered slow, any number ~200,000 digits long from what I've seen is practical, larger numbers will obviously be slower, it also depends on what the number is. For 2 random numbers I made both with exactly 200,000 digits, it took 134,369 milliseconds, or 134.369 seconds or, 2.240 minutes.

There is also a bottleneck or bug (what ever you want to called it) somewhere, when adding a large number with one of less digits or vice-verse, it takes longer then adding 2 large numbers of the same number of digits, I might fix it sometime later.

Comments would be nice, If you haven't noticed I am bored and making small programs lol.

No comments: