Article Categories
- All Categories
-
Data Structure
-
Networking
-
RDBMS
-
Operating System
-
Java
-
MS Excel
-
iOS
-
HTML
-
CSS
-
Android
-
Python
-
C Programming
-
C++
-
C#
-
MongoDB
-
MySQL
-
Javascript
-
PHP
-
Economics & Finance
Articles on Trending Technologies
Technical articles with clear explanations and examples
A square matrix as sum of symmetric and skew-symmetric matrix ?
A square matrix can be expressed as the sum of a symmetric matrix and a skew-symmetric matrix. This decomposition is unique and provides insight into the structure of any square matrix. Symmetric Matrix − A matrix whose transpose is equal to the matrix itself (A = AT). Skew-symmetric Matrix − A matrix whose transpose is equal to the negative of the matrix (A = -AT). Syntax A = (1/2)(A + A^T) + (1/2)(A - A^T) Where: (1/2)(A + A^T) is the symmetric part (1/2)(A - A^T) is the skew-symmetric part ...
Read MoreCSS cue-after Property
The CSS cue-after property specifies a sound to be played after speaking an element's content in speech synthesis. This property is part of CSS Speech Module and is used by screen readers and other assistive technologies to provide audio cues that help separate content elements. Syntax selector { cue-after: value; } Possible Values ValueDescription url()Specifies the URL of a sound file to be played noneNo sound will be played (default value) Example The following example demonstrates how to add audio cues after different elements − ...
Read MoreSum of square of first n odd numbers
The sum of squares of first n odd numbers is a mathematical series where we calculate the squares of the first n odd numbers and add them together. The first n odd numbers are: 1, 3, 5, 7, 9, 11, ... and their squares form the series: 12, 32, 52, 72, 92, 112, ... which equals 1, 9, 25, 49, 81, 121, ... Syntax sum = n(2n+1)(2n-1)/3 = n(4n² - 1)/3 Where n is the count of odd numbers to consider. Method 1: Using Loop Iteration This approach calculates each odd number, squares it, and adds to the sum − #include int main() { int n = 4; int sum = 0; for (int i = 1; i
Read MoreFade Out Animation Effect with CSS
The CSS fade out animation effect gradually transitions an element from fully visible (opacity: 1) to completely invisible (opacity: 0). This creates a smooth disappearing effect that's commonly used for image galleries, modal closures, and interactive elements. Syntax @keyframes fadeOut { 0% { opacity: 1; } 100% { opacity: 0; } } .element { animation-name: fadeOut; animation-duration: time; animation-fill-mode: both; } Example: Basic Fade Out Effect The following example demonstrates a fade out ...
Read MoreSum of all subsets of a set formed by first n natural numbers
A set is a collection of data elements. A subset of a set is a set formed by selecting some or all elements from the parent set. For example, B is a subset of A if all elements of B exist in A. Here we need to find the sum of all subsets of a set formed by first n natural numbers. This means we need to find all possible subsets and then add up all their elements. Understanding the Problem Let's take an example with N = 3: Set = {1, 2, 3} All ...
Read MoreFade In Up Big Animation Effect with CSS
The CSS fadeInUpBig animation effect creates a dramatic entrance where an element slides up from far below the viewport while fading in. This animation is perfect for hero sections, large images, or content that needs to make a bold visual impact. Syntax @keyframes fadeInUpBig { 0% { opacity: 0; transform: translateY(2000px); } 100% { opacity: 1; ...
Read MoreSum of series with alternate signed squares of AP
An arithmetic progression (AP) is a series of numbers in which the difference between two consecutive terms is the same. The difference is calculated by subtracting the first term from the second. Let's take a sample sequence to understand AP − 5, 7, 9, 11, 13, 15, . . . The common difference (d) of this arithmetic progression is 2. This means every succeeding element differs from the former one by 2. The first term (a) of this series is 5. The general formula for finding the nth term is an = a + (n-1) × d ...
Read MoreFade In Animation Effect with CSS
CSS fade-in animation creates a smooth visual effect where elements gradually transition from transparent to opaque. This effect is commonly used to enhance user interaction by drawing attention to specific elements like buttons, images, or text when users hover over them. Syntax selector { opacity: initial-value; transition: opacity duration; } selector:hover { opacity: final-value; } Key Properties PropertyDescriptionValues opacityControls transparency level0 (transparent) to 1 (opaque) transitionDefines animation duration and timingTime in seconds (s) or milliseconds (ms) Example 1: ...
Read MoreSum of series 2/3 – 4/5 + 6/7 – 8/9 + ...... upto n terms
In C programming, we can calculate the sum of the series 2/3 − 4/5 + 6/7 − 8/9 + ...... up to n terms. This is an alternating series where each term has the form (-1)n+1 * (2*n) / (2*n + 1). Syntax double calculateSeriesSum(int n); Understanding the Series Pattern The series follows this pattern − First term: 2/3 (positive) Second term: -4/5 (negative) Third term: 6/7 (positive) Fourth term: -8/9 (negative) For the nth term: (-1)n+1 * (2*n) / (2*n + 1) Example: Calculate Series Sum Here's a complete C program to calculate the sum of this series − #include double calculateSeriesSum(int n) { double sum = 0.0; int sign = 1; for (int i = 1; i
Read MoreAchieve X-Ray effect with CSS
The X-Ray effect in CSS is an Internet Explorer specific filter that converts colors to grayscale and flattens the color depth, creating a distinctive visual appearance similar to an X-ray image. Syntax selector { filter: Xray; } Parameters Parameter Description Xray Grayscales and flattens the color depth of the element Example The following example demonstrates how to apply the X-Ray filter effect to both images and text − .xray-image { ...
Read More