Question: what is the correct formula to calculate charge q?
Answer: The equation is: charge (coulomb, C) = current (ampere, A) × time (second, s). For example, if a a current of 20 A flows for 40 s, the calculation is 20 × 40.