Skip to content

Category Archives: C++ Programs

Given an integer N, the task is to print the Alphabet Z Pattern as given below:  1 2 3 * * * N * *… Read More
Given a square matrix mat[][] of odd dimensions, the task is to change the value of the middle most element of the matrix to the… Read More
Given an array arr, the task is to replace each element of the array with the element that appears after it and replace the last… Read More
Given an array arr, the task is to replace each element of the array with the element that appears before it and replace the first… Read More
Given two positive integers L and R, the task is to count the elements from the range [L, R] whose prime factors are only 2… Read More
Given a singly linked list containing N nodes, the task is to delete all nodes from the list which are not prime. Examples:  Input :… Read More
Given a number N, the task is to find the required numbers consist of only 0 and 1 digit whose sum is equal to N.… Read More
Given a number . The task is to find the N-th term in the following series:   14, 28, 20, 40, 32, 64…..   Examples:   Input : N… Read More
Given an N*N matrix. The task is to convert the elements of diagonal of a matrix to 0. Examples:  Input: mat[][] = {{ 2, 1,… Read More
Given a right circular cylinder of radius and height . The task is to find the radius of the biggest sphere that can be inscribed within it.Examples:  … Read More
Given a sphere of radius . The task is to find volume of the biggest right circular cylinder that can be inscribed within it.Examples:   Input :… Read More
Given a right circular cylinder of height , & radius . The task is to find the length of the longest rod that can be inserted within… Read More
CSV is a simple file format used to store tabular data such as a spreadsheet or a database. CSV stands for Comma Separated Values. The… Read More
Given a string of lowercase English alphabets. The task is to check if the count of distinct characters in the string is prime or not.… Read More
Given an integer and two integer arrays H[] and C[] of size where H[] stores the height of consecutive buildings and C[] stores the color codes for… Read More

Start Your Coding Journey Now!