Domanda di colloquio di Apryse

How to multiply a number by 7 without using + and * operators?

Risposte di colloquio

Anonimo

14 ott 2010

use bit shifting.

1

Anonimo

23 gen 2013

n=n<<3-n

1

Anonimo

9 ago 2013

do the left.bit shift operation by 3 and then subtract the result by original number . eg: n=1 ,then n=n<<3 -n gives 7 , if n=2 ,then gives 14