Histrogram for an assigment

I'm new here kindly can you guide me what is the codding for histrogram

A histogram displays the counts of a single variable. If the variable is continuous, the values are placed into bins, which are equal-interval ranges into which the data are divided.

hist(mtcars$mpg)

Created on 2023-11-20 with reprex v2.0.2