The invention proposes a cooker, comprising: a container, configured to receive food; a vibration generator coupled with the container, configured to generate vibration; and a controller coupled with the vibration generator, configured to control the vibration generator to vibrate the container to cause food movement in the container. The invention also proposes a method of cooking food in a container, comprising the steps of: heating the food in the container; and controlling a vibration generator to vibrate the container so as to cause the food in the container to move during the heating process.