Pergunta de entrevista da empresa Zynga

1. Write division method without using "/" operator 2. Reverse linked list 3. w.r.t. memory, explain why arrays are preferred over Linked lists (other than the get() method) 4. determine is a number is prime

Resposta da entrevista

Sigiloso

15 de dez. de 2012

1. Can use loop and - operator 2. Can do this recursively or iteratively 3. has to do with cache 4. only need to check mod == 0 for numbers 2 to n / 2