Clocks use different ways to measure time. Clocks need some sort of steady
beat or motion to track the change in time. Ancient
water clocks worked by the steady movement of water from a container with a hole in the bottom to another container without a hole. Other clocks use pendulums, springs and gears to track the change in time correctly.
Digital clocks work by measuring the vibrations of quartz crystals when charged with electricity. The vibration frequency of the crystal does not change.
Atomic clocks use the electromagnetic waves absorbed and emitted by atoms such as caesium to measure time. They are the most precise clocks in the world.