Google News
logo
CSS - Interview Questions
Differentiate between inline and block element.
Inline element does not have an element to set width and height and also it does not have the line break.
 
Example : em, strong, etc.
 
Block element specification:
 
They do have the line break.

They define the width by setting a container and also allow setting height.
It can also contain an element that occurs in the inline element.

Example :
 
width and height
max-width and max-height
min-width and min-height
hi (i=1-6)- heading element
p- Paragraph element.
Advertisement