Articles on Trending Technologies

Technical articles with clear explanations and examples

What to do when an element's content might be larger than the amount of space allocated to it?

karthikeya Boyini
karthikeya Boyini
Updated on 15-Mar-2026 176 Views

The CSS overflow property controls what happens when an element's content is too large to fit in the allocated space. This property allows you to specify whether content should be clipped, scrollable, or visible. Syntax selector { overflow: value; } Possible Values ValueDescription visibleContent overflows the element's boundary (default) hiddenContent is clipped and hidden scrollAdds scrollbars to view overflowing content autoAdds scrollbars only when needed Example: Using Scroll and Auto Values The following example demonstrates how overflow: scroll and overflow: auto handle content that exceeds container ...

Read More

Print multiples of Unit Digit of Given Number in C Program

Sunidhi Bansal
Sunidhi Bansal
Updated on 15-Mar-2026 5K+ Views

In C programming, finding multiples of the unit digit of a given number involves extracting the last digit and then finding all numbers that divide it evenly. The unit digit of any number can be obtained using the modulo operator (%) with 10. Syntax int unitDigit = number % 10; Algorithm START Step 1 → Declare variables num, unitDigit and i Step 2 → Input number num Step 3 → Store num%10 in unitDigit to fetch unit digit Step 4 → Print unitDigit Step 5 → Loop for i=2 and i

Read More

Which property is used to tell the browser what to do if the box's content is larger than the box itself?

Arjun Thakur
Arjun Thakur
Updated on 15-Mar-2026 269 Views

CSS provides a property called overflow which tells the browser what to do if the box's content is larger than the box itself. Syntax selector { overflow: value; } Possible Values Value Description visible Allows the content to overflow the borders of its containing element (default) hidden The content is clipped at the border and no scrollbars are visible scroll Scrollbars are always added, allowing users to scroll to see overflowing content auto Scrollbars appear only if ...

Read More

Area of a square inscribed in a circle which is inscribed in an equilateral triangle in C Program?

sudhir sharma
sudhir sharma
Updated on 15-Mar-2026 223 Views

The program finds the area of a square inscribed in a circle which is inscribed in an equilateral triangle. When a circle is inscribed in an equilateral triangle of side length a, the radius of the circle is a/(2√3). The diameter of the inscribed circle becomes the diagonal of the square: d = 2 * r = a/√3. Using the formula for the area of a square given its diagonal (1/2) * d², we get: Area = (1/2) * (a²/3) = a²/6. ...

Read More

Usage of margin-right property with CSS

Lakshmi Srinivas
Lakshmi Srinivas
Updated on 15-Mar-2026 92 Views

The CSS margin-right property specifies the right margin of an element. It controls the space between the element and adjacent elements or the container's edge on the right side. Syntax selector { margin-right: value; } Possible Values ValueDescription lengthDefines margin in px, em, rem, etc. %Defines margin as a percentage of parent element's width autoBrowser calculates the margin automatically Example 1: Using Length Values The following example demonstrates margin-right using pixel values − .container { ...

Read More

C vs BASH Fork bomb?

sudhir sharma
sudhir sharma
Updated on 15-Mar-2026 368 Views

A fork bomb is a Denial of Service (DoS) attack that exploits the fork() system call to create an exponentially growing number of processes, eventually exhausting system resources. Both BASH and C can implement fork bombs, but they work differently. Syntax pid_t fork(void); BASH Fork Bomb The classic BASH fork bomb is a compact one-liner − :(){ :|: & };: This code works as follows: :() − Defines a function named : { :|: & } − Function body that pipes itself to itself and runs in background ...

Read More

Create layers using CSS

Ankith Reddy
Ankith Reddy
Updated on 15-Mar-2026 97 Views

To create layers using CSS, you can control the stacking order of elements using the z-index property combined with positioned elements. This allows you to stack elements on top of each other and control which element appears in front. Syntax selector { position: relative | absolute | fixed | sticky; z-index: integer; } How Z-Index Works The z-index property only works on positioned elements (elements with position other than static). Higher z-index values appear on top of lower values. Z-Index ValueStacking Order Higher numbers ...

Read More

CSS min-width property

Chandu yadav
Chandu yadav
Updated on 15-Mar-2026 188 Views

The CSS min-width property sets the minimum width that an element can have. This property ensures that an element will never become smaller than the specified minimum width, even if the content would normally make it narrower. Syntax selector { min-width: value; } Possible Values ValueDescription lengthDefines minimum width in px, em, rem, etc. %Defines minimum width as a percentage of the parent element autoDefault value; browser calculates the minimum width Example: Setting Minimum Width The following example demonstrates how min-width prevents an element from becoming ...

Read More

Sum of squares of first n natural numbers in C Program?

sudhir sharma
sudhir sharma
Updated on 15-Mar-2026 14K+ Views

In C programming, finding the sum of squares of the first n natural numbers means calculating 12 + 22 + 32 + ... + n2. This is a common mathematical problem that can be solved using different approaches. Example: For n = 5, the sum is 12 + 22 + 32 + 42 + 52 = 1 + 4 + 9 + 16 + 25 = 55 Syntax // Using loops for(int i = 1; i

Read More

CSS max-height property

Lakshmi Srinivas
Lakshmi Srinivas
Updated on 15-Mar-2026 146 Views

The CSS max-height property sets the maximum height that an element can reach. When content exceeds this maximum height, it will overflow or be clipped depending on the overflow property. Syntax selector { max-height: value; } Possible Values ValueDescription lengthA fixed height in px, em, rem, etc. percentageA percentage of the containing block's height noneNo maximum height limit (default) initialSets to default value inheritInherits from parent element Example: Text Content with Max Height The following example shows how max-height affects text content that exceeds the specified ...

Read More
Showing 21621–21630 of 61,297 articles
Advertisements