

InterviewSolution
Saved Bookmarks
1. |
Computer science#convert the decimal following |
Answer» <html><body><p><strong>Answer:</strong></p><p>265=411</p><p>135=111</p><p>436=1B4</p><p><strong>Explanation: for <a href="https://interviewquestions.tuteehub.com/tag/dec-435584" style="font-weight:bold;" target="_blank" title="Click to know more about DEC">DEC</a> to octal</strong></p><p>Write the given <a href="https://interviewquestions.tuteehub.com/tag/decimal-435752" style="font-weight:bold;" target="_blank" title="Click to know more about DECIMAL">DECIMAL</a> number</p><p>If the given decimal number is less than 8 the octal number is the same.</p><p>If the decimal number is greater than 7 then divide the number by 8.</p><p>Note the remainder, we get after division</p><p>Repeat step 3 and 4 with the quotient till it is less than 8</p><p>Now, write the remainders in reverse order (bottom to top)</p><p>The resultant is the equivalent octal number to the given decimal number.</p><p></p><p>for converting decimal to binary</p><p>Divide the number by <a href="https://interviewquestions.tuteehub.com/tag/2-283658" style="font-weight:bold;" target="_blank" title="Click to know more about 2">2</a>.</p><p>Get the integer quotient for the next iteration.</p><p>Get the remainder for the binary digit.</p><p>Repeat the steps until the quotient is equal to 0.</p><p></p><p>for dec to hexa</p><p>Divide the decimal number by 16. Treat the division as an integer division.</p><p>Write down the remainder (in hexadecimal).</p><p>Divide the <a href="https://interviewquestions.tuteehub.com/tag/result-1187343" style="font-weight:bold;" target="_blank" title="Click to know more about RESULT">RESULT</a> again by 16. Treat the division as an integer division.</p><p>Repeat step 2 and 3 until result is 0.</p><p>The hex value is the digit sequence of the remainders from the last to first.</p><p></p><p>hoping that it will help you!</p></body></html> | |