We have I1=−120A,I2=720A,I3=−620A.
In each cell, thermal energy will be dissipated due to internal resistance whether the chemical energy of the cell is increasing or decreasing.
i. Cell I is getting charged, hence its chemical energy increases.
ii. Cells II and III both are getting discharged, hence their chemical energies are decreasing. So work done by both of them is positive.
iv. Cell IV is getting charged, hence its chemical energy increases.