Lattice Semiconductor Interview Question

Basic technical question like, identify the bug in a C program; identify the functionality of a circuit; find out the algorithm on a case study and what is the Big-O notation. Draw the circuit and truth table for a function.