<span>Even though the Sun has a greater mass than Earth, the Moon orbits Earth because it's closer to the Earth than to the Sun. Because of this proximity between the Earth and the Moon, the Earth has a stronger gravitational pull than the Sun does. Furthermore, the Earth's mass is 81 times that of the Moon, and so at this proximity, it is more than able to overpower what pull the Sun exerts on the Moon.</span>
Why do teachers give such hard questions? anyways hopefully your question will get answered! (btw i also need the points but yeah gl!!!)
fyt as per the question the magnitude of two like charges are given as q1 and q2.the separation distance is given as r unit.hence the potential energy is given as-
here the potential energy is positive which means the force between two charges is repulsive.the potential energy is maximum which indirectly denotes that the system is unstable.due to this repulsion the smaller charge may accelerate.
coming to the same charges of opposite nature i.e unlike charges-here the magnitude of charges are same and separation distance is also are,so the potential energy will be given as-
here the potential energy is negative .so the system of two charges are attracted by each other.