Continental Interview Question

What is a capacitor, resistor, active passive component how they behave in a basic circuit Make a few easy function in C