工程與科技
大學

計概 師大資工104年轉學考考古題
想請問這題:D

Assuming that no overflow occurs, how many times do we have to apply the arithmetic left shift operation to multiply an integer by 4? (A) 1 (B) 2 (C) 3 (D) 4 參考解答: B
計算機概論
PromotionBanner

解答

十進位 二進位
1 0001
4 0100
二進位的1左移兩次就變成二進位的4了,因此答案為2。

也可以說,2的2次方=4,2的0次方=1,2-0=2,答案為2。

留言
您的問題解決了嗎?