What is the use of a transistor?