At Fixya.com, our trusted experts are meticulously vetted and possess extensive experience in their respective fields. Backed by a community of knowledgeable professionals, our platform ensures that the solutions provided are thoroughly researched and validated.
- If you need clarification, ask it in the comment box above.
- Better answers use proper spelling and grammar.
- Provide details, support with references or personal experience.
Tell us some more! Your answer needs to include more details to help people.You can't post answers that contain an email address.Please enter a valid email address.The email address entered is already associated to an account.Login to postPlease use English characters only.
Tip: The max point reward for answering a question is 15.
Dinary? Never heard that one before. What is a dinary number? Anyway your calculator cannot perform the operations. The Casios can work in Binary (base 2), Octal (base 8), Decimal (base 10) and Hexadecimal (base 16). Some Sharps can do calculations in base 5 (pental).
If you want to convert from another base to decimal, press MODE 4 to enter the BASE-N mode, select the initial base (binary, octal, or hexadecimal), enter the number, then switch to decimal to see the value in decimal. If you want to exit the BASE-N mode, press MODE 1 to switch to the computational model or MODE 2 for complex mode.
Letters can be converted into decimal number using ASCII table. Every Character has it own equivalent number. Once converted into decimal (base 10), I could be easily converted into binary (base 2)
You could also use applications or web based applications such as ASCII to binary converter to help you convert it.
If you're already in decimal mode, press SHIFT BIN to switch to binary mode.
To convert a number from decimal to binary, press MODE 4 to switch to BASE-N mode. You'll find yourself in decimal mode. Enter the number to convert, press =, then press SHIFT [BIN] (the log key) and see the number in binary. To convert another number, press SHIFT [DEC] to return to decimal, enter the number, press =, then press SHIFT [BIN]. An analogous process works for hexadecimal and octal as well.
To return to "normal" use, press MODE 1 for COMP mode or MODE 2 for complex mode.
Press MODE 4 to enter the BASE-N mode. Type in the decimal number, then press BIN to convert to binary. Press DEC to switch back to decimal for the next conversion.
You're limited to numbers in the range [-32768...32767] in binary. You can extend the range if you convert to octal or hexadecimal and then mentally convert each digit to three or four bits.
Convert the octal, hexadecimal or binary to decimal.
Add or Subtract the decimal normally
Convert the result back to octal, hexadecimal or binary.
Convert the octal to decimal:
publicstaticlong octalToDecimal(String octal)throwsNumberFormatException{ // Initialize result to 0 long res =0;
// Do not continue on an empty string if(octal.isEmpty()){ thrownewNumberFormatException("Empty string is not an octal number"); }
// Consider each digit in the string for(int i =0; i < octal.length(); i++){ // Get the nth char from the right (first = 0) char n = octal.charAt(octal.length()-(i+1));
int f =(int) n -48; // Check if it's a valid bit if(f <0|| f >7){ // And if not, die horribly thrownewNumberFormatException("Not an octal number"); }else{ // Only add the value if it's a 1 res += f*Math.round(Math.pow(2.0,(3*i))); } }
×