Is it possible to make the height dependent on the width?

Is it possible to make the height of the block was equal to his width, or width of another block. Or width is equal to the height of the block. I.e. if the block of interest ass width, for example 25% to the height was also equal to 25% but not the width, or simply to equate these two values.
Not sure I'm correctly asked the question, I hope at least someone will understand)
March 19th 20 at 08:39
4 answers
March 19th 20 at 08:41
Solution
Distribute quick. This is this:
https://jsfiddle.net/jr87acqg/1/

Move the width of the block and look
March 19th 20 at 08:43
Solution
March 19th 20 at 08:45
Solution
proinspektirovat video here and see how it is done
https://getbootstrap.com/docs/4.3/utilities/embed/
there is height through paging
.embed-responsive-16by9::before {
 padding-top: 56.25%;
}
March 19th 20 at 08:47
I started with https://learn.javascript.ru And then the book serious uncles-type Flanegan

Find more questions by tags Web DevelopmentLayoutHTMLCSS