The two or more different div of same height can be put side-by-side using CSS. Use CSS property to set the height and width of div and use display property to place div in side-by-side format.
The used display property are listed below:
- display:table; This property is used for elements (div) which behaves like table.
- display:table-cell; This property is used for elements (div) which behaves like td.
- display:table-row: This property is used for elements (div) which behaves like tr.
Example 2: This example contains multiple number of div put into side-by-side using CSS.
- Place K-knights such that they do not attack each other
- Ways to place K bishops on an N×N chessboard so that no two attack
- CSS | height Property
- CSS | Height and Width
- CSS | max-height Property
- CSS | min-height Property
- CSS | line-height Property
- HTML | Screen height Property
- How to make div height expand with its content using CSS ?
- How to give a div tag 100% height of the browser window using CSS
- HTML | DOM Style height Property
- Minimum height of a triangle with given base and area
- Maximum height of triangular arrangement of array values
- Check whether product of digits at even places is divisible by sum of digits at odd place of a number
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.