Here is a short tutorial on why DC/DC buck converters need capacitors on the input and how it works in a power design.
If a larger value of resistance were used with the same value of capacitance in the above circuit, then a smaller current would flow, therefore it would take longer for the capacitor to charge up ...
The gradient of this graph is equal to the capacitance of the capacitor. \(C= \frac{Q}{V}\) And the area under the graph is the energy stored by the capacitor.