Why is squaring a number faster than multiplying two random numbers?

前端 未结 14 2097
终归单人心
终归单人心 2021-01-30 07:18

Multiplying two binary numbers takes n^2 time, yet squaring a number can be done more efficiently somehow. (with n being the number of bits) How could that be?

Or is i

14条回答
提交回复
热议问题