What is the function of a resistor in a circuit? How does it affect the amount of charge that flows? How does it affect the rate at which charge flows? How does it affect the initial and final voltage across the capacitor?