Hi

Q = It, where Q is charge, I is current, and t is time. In case of capacitor I is maximum, I0, at t0 (when the switch is just closed). The current will decrease gradually in exponential fashion. We can find the total charge, Q=It, which flows into the capacitor until the potential difference across it equalizes the potential difference of the battery.

Energy = VI x t. Therefore, we can write, Energy = VQ.

The battery supplied all the charge which went into the capacitor at constant potential, V.

But the formula for power or work done for capacitor is: 1/2 VQ. It's half the work done by battery. Where did the rest of the energy, which is half of the supplied energy, go?

This is what I think. As a capacitor gets charged, the battery finds it hard to push the charge into the capacitor because the capacitor starts resisting the inflow of the charge. Therefore, half of the energy gets lost as heat. This is analogous to the case when air is blown into a balloon. As the balloon gets inflated, it starts resisting the inflow of the air.

Do I make sense? Please let me know. Thanks.

Regards

PG