An earthquake’s when the earth plates slip apart, then a big crack is formed and the ground rumbles. That is an earthquake, it usually lasts 10 - 30 seconds.
Going under a table or desk and hold on the the desk or table legs, and the desk or table needs to cover you’re whole body, so then falling debris don’t fall on you
If your table at home is crushed by debris then run out in the open outside to not get hit by a building.