Pergunta de entrevista da empresa Qualcomm

Function to convert a integer to a binary string

Respostas da entrevista

Sigiloso

5 de jun. de 2013

I ll simply put the pseudo code : //binary_num will contain the string //dec_num already contains the number k=0; do { binary_num[k]=dec_num%2; dec_num/=2; k++; }while(dec_num>1);

Sigiloso

5 de jun. de 2013

I ll simply put the pseudo code : //binary_num will contain the string //dec_num already contains the number k=0; do { binary_num[k]=dec_num%2; dec_num/=2; k++; }while(dec_num>0);