==========================================
Size needed for output of ADD and MULTIPLY
==========================================
- Ian! D. Allen - idallen@idallen.ca - www.idallen.com
* Addition of two Integers
1) If you have two 8-digit integers, any base, and you add them together,
how many digits are required to hold the largest result?
2) If the numbers are 5 digits, 10 digits, or "N" digits,
how many digits are required for the result?
3) If the numbers are octal, hex, or binary digits, is the formula for the
resulting number of octal, hex, or binary digits different? (Hint: No.)
* Multiplication of two Integers
1) If you have two 8-digit integers, any base, and you multiply them together,
how many digits are required to hold the largest result?
2) If the numbers are 5 digits, 10 digits, or "N" digits,
how many digits are required for the result?
3) If the numbers are octal, hex, or binary digits, is the formula for the
resulting number of octal, hex, or binary digits different? (Hint: No.)
Questions:
1. If you add together two 100 bit binary integers, how many bits
are required to store the largest result?
2. If you multiply together two 100 bit binary integers, how many bits
are required to store the largest result?
--
| Ian! D. Allen - idallen@idallen.ca - Ottawa, Ontario, Canada
| Home Page: http://idallen.com/ Contact Improv: http://contactimprov.ca/
| College professor (Free/Libre GNU+Linux) at: http://teaching.idallen.com/
| Defend digital freedom: http://eff.org/ and have fun: http://fools.ca/