Ask Question
23 July, 20:41

4-One possible performance multiplication enhancement is to do a shift and add instead of an actual multiplication. Since 9 * 6, for example, can be written (2 * 2 * 2 + 1) * 6, we can calculate 9 * 6 by shifting 6 to the left 3 times and then adding 6 to that result. Show the best way to calculate 13 * 7 using shifts and adds/subtracts. Assume both inputs are 8-bit unsigned integers.

+5
Answers (1)
  1. 23 July, 21:55
    0
    Check the explanation

    Explanation:

    The above question can be sovled in the below step by step way:

    15 can be written as 16-1 = 24 - 1

    Therefore, 15 * 13 = (24 - 1) * 13

    = 13*24 - 13

    Now, when we left shift a number we multiply it by 2k. Where k is no of times we left shifted it.

    Therefore, 13*24 = shift 13 to left 4 times

    15 * 13 = shift 13 to left 4 times and subtract 13 from it.
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “4-One possible performance multiplication enhancement is to do a shift and add instead of an actual multiplication. Since 9 * 6, for ...” in 📙 Computers & Technology if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers