I have div with some child element, my requirement is if there is 2 child they take 50%-50% with of parent but if there are more than 2 child element they should we take 100% with each. only with css
senerico one :
<div class="parent">
<div class="child">1</div>
<div class="child">2</div>
</div>
expect result child width 50%
senerico two :
<div class="parent">
<div class="child">1</div>
<div class="child">2</div>
<div class="child">3</div>
</div>
expect result child width 100%