|Release Date:||March 17, 2015|
|Development Status:||Finished (Probably)|
|Language(s):||Any language that recognizes the Arabian-based counting system.|
As a small project, I created a simple change-of-base translator. A base (or Radix) is simply the means at which we perceive numbers, for instance the counting system that we use is typically base 10, since we count using ten digits with a 1s place, 10s place, 100s place, etc (base^place, assuming that you start at 0 for the place). Computers often count in base 2 or binary; base 8, or octal; or base 16 or hexadecimal. My application allows easy translations between any base from 2 to 16, assuming that you know what you're doing.
Choose your IBASE (input base) before you type in numbers. Your input will be outputted onto the top screen. At any time in the process, you may change what the OBASE (output base) is, but it will not update if you have already pressed Enter. It should be noted that when you press enter, the input is cleared, meaning that you will not need to press backspace to clear your 17-digit long binary sequence. This also means that you can't translate your sequence from IBASE to OBASE and then directly into a different OBASE without retyping the number.
- Initial and perhaps Final Release. We'll see.
If I receive enough requests to change or add something, I will likely leap to the cause.
Videos and ScreenshotsEdit
No videos or screenshots. My apologies. :(
The MIT License (MIT)
Copyright © 2015 Enkrypted
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Since the binary limitations on Petit Computer are quite noticeable (I believe it is 18 bits for integers), the program limits your input to ensure (hopefully) that you do not overflow the variable. This is the reasoning behind the variable input length.
As a note, the letters A to G are used to represent the numbers 10 to 16. For instance, A would be 10, B is 11,... G is 16. So to translate an input of base 10 to base 8, set the IBASE to A and the OBASE to 8.
I made this partially for a class, so I had to write and outline. If you would like to view the outline (contains a rather detailed explanation of the code), then feel free to view it here.
Enkrypted - Creator, etc.