Articles on Trending Technologies

Technical articles with clear explanations and examples

Role of CSS flex-wrap property no-wrap value

Nishtha Thakur
Nishtha Thakur
Updated on 15-Mar-2026 303 Views

The CSS flex-wrap property with nowrap value prevents flex items from wrapping to new lines, keeping all items on a single row even if they overflow the container. Syntax selector { flex-wrap: nowrap; } Example The following example demonstrates how nowrap forces all flex items to stay on one line − .mycontainer { display: flex; background-color: orange; ...

Read More

C program to store Student records as Structures and Sort them by Name

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

In this problem, we are given a student's record which contains student_id, student_name, and student_percentage. Our task is to create a C program to store student records as structures and sort them by name using string comparison. Syntax struct Student { int student_id; char student_name[50]; int student_percentage; }; int qsort(void *base, size_t nitems, size_t size, int (*compar)(const void *, const void*)); Example Input and Output Input − student record − { student_id = 1, student_name = Nupur, student_percentage = ...

Read More

Change the padding of a button with CSS

Yaswanth Varma
Yaswanth Varma
Updated on 15-Mar-2026 5K+ Views

The CSS padding property allows you to control the space between a button's content (text or icon) and its borders. This spacing is crucial for creating visually appealing and user-friendly buttons that are easy to click. Syntax button { padding: value; } Possible Values ValueDescription lengthDefines padding in px, em, rem, etc. %Percentage of the containing element's width top right bottom leftFour values for each side individually vertical horizontalTwo values for vertical and horizontal padding Example 1: Different Padding Values The following example shows buttons with ...

Read More

Maximum number of threads that can be created within a process in C

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

In this article, we will explore how to determine the maximum number of threads that can be created within a process in C. Understanding thread limits is crucial for developing efficient multi-threaded applications. A thread is a lightweight process that can be independently managed by the scheduler. Multiple threads can be associated with a single process, and they require less time for context switching compared to processes. Threads share memory with their peer threads and require fewer resources for creation and termination. Syntax int pthread_create(pthread_t *thread, const pthread_attr_t *attr, ...

Read More

Change the font size of a button with CSS

George John
George John
Updated on 15-Mar-2026 27K+ Views

To change the font size of a button with CSS, you can use different properties to control text appearance. The font size affects button readability and visual hierarchy on your webpage. Syntax button { font-size: value; } Method 1: Using font-size Property The CSS font-size property directly controls the text size inside buttons. This is the most straightforward approach − Example .normal-btn { font-size: 16px; ...

Read More

Count minimum bits to flip such that XOR of A and B equal to C in C++

Sunidhi Bansal
Sunidhi Bansal
Updated on 15-Mar-2026 464 Views

We are given three binary sequences A, B and C of length N. Each sequence represents a binary number. We have to find the number of bit flips required in A and B such that XOR of A and B results in C. Syntax int flipCount(int A[], int B[], int C[], int n); First, let us understand the XOR operation truth table − X ...

Read More

Find a permutation that causes worst case of Merge Sort in C

Arnab Chakraborty
Arnab Chakraborty
Updated on 15-Mar-2026 389 Views

Merge sort has a consistent O(n log n) time complexity, but in practice, certain input permutations require more comparisons during the merge operations. The worst case occurs when the merge operation at each level compares every element from both subarrays before completing. Syntax void generateWorstCase(int arr[], int left, int right); Understanding the Worst Case The worst case for merge sort happens when at each merge operation, elements from left and right subarrays are alternately selected. This forces maximum comparisons since we cannot skip any elements during merging. Algorithm To generate the worst ...

Read More

Role of CSS flex-wrap property wrap-reverse value

Smita Kapse
Smita Kapse
Updated on 15-Mar-2026 275 Views

The CSS flex-wrap property with wrap-reverse value allows flex items to wrap to new lines in reverse order. When flex items exceed the container width, they wrap from bottom to top instead of the default top to bottom behavior. Syntax .container { display: flex; flex-wrap: wrap-reverse; } Example The following example demonstrates how wrap-reverse wraps flex items in reverse order − .mycontainer { display: flex; ...

Read More

Change the background color of a button with CSS

Chandu yadav
Chandu yadav
Updated on 15-Mar-2026 2K+ Views

To change the background color of a button, use the background-color property in CSS. This property allows you to set any color value to customize the button's appearance. Syntax button { background-color: value; } Possible Values ValueDescription Color namePredefined color names like red, blue, yellow Hex codeHexadecimal values like #FF0000, #00FF00 RGBRGB values like rgb(255, 0, 0) HSLHSL values like hsl(120, 100%, 50%) Example: Yellow Background Button The following example demonstrates how to change a button's background color to yellow − ...

Read More

fillpoly() function in C

Arnab Chakraborty
Arnab Chakraborty
Updated on 15-Mar-2026 798 Views

The fillpoly() function in C is part of the graphics.h library and is used to draw and fill a polygon with the current fill pattern and color. It takes the same arguments as drawpoly() but additionally fills the interior of the polygon. Syntax void fillpoly(int numpoints, int *polypoints); Parameters numpoints − Specifies the number of points in the polygon polypoints − Pointer to an array containing x, y coordinates of each point The polypoints array should contain numpoints * 2 integers, where each pair represents the x and y coordinates of ...

Read More
Showing 20981–20990 of 61,297 articles
Advertisements