Ajay yadav has Published 48 Articles

Replacing words with asterisks in C++

Ajay yadav

Ajay yadav

Updated on 29-Nov-2019 11:04:24

509 Views

This aim of this program to replace a particular word with asterisks in the string by using the c++ programming code. The essential function of vector and string class essay a key role to achieve the prospective results. The algorithm is as follows;AlgorithmSTART    Step-1: Input string    Step-2 Split ... Read More

Reverse a link list using stack in C++

Ajay yadav

Ajay yadav

Updated on 29-Nov-2019 10:59:50

129 Views

Linked list allocates memory dynamically, is used to implement a stack. This program showcase the reversal of the link list in c++ programming. Here, the aspirant can adopt the following approach to get the expected results. The algorithm is as follows;AlgorithmSTART    Step 1: create an empty stack of type ... Read More

Replacing space with a hyphen in C++

Ajay yadav

Ajay yadav

Updated on 29-Nov-2019 10:55:18

2K+ Views

In this C++ program, the space in the string will be replaced with the hyphen. Firstly, the length of the string is determined by the length() function of the cstring class, then hyphen is filled into the space of the sentence by traversing the string as follows.Example Live Demo#include #include ... Read More

Sqrt, sqrtl, and sqrtf in C++ programming

Ajay yadav

Ajay yadav

Updated on 29-Nov-2019 10:52:02

166 Views

Math ClassThis article demonstrates the usage of math class essentials functions sqrt(), sqrtl(), and sqrtf() to calculate the square root of double, long, and float type variables with precision respectively. The Math class of C++ offers a wide range of functions to calculate mathematical calculations including sin, cos, square root, ... Read More

String at () in C++

Ajay yadav

Ajay yadav

Updated on 29-Nov-2019 10:46:04

457 Views

AbstractThis short tutorial is an overview of the C++ String class at() functionality in order to access a sequence of characters from the string. In the forthcoming section, an aspiring reader can through string class programming examples to get a thorough understanding of the manipulation of at() functions.String ClassIn programming ... Read More

Swap Upper diagonal with Lower in C++

Ajay yadav

Ajay yadav

Updated on 29-Nov-2019 10:42:25

181 Views

This tutorial is designed to swap the upper row of a three-diagonal array to its lower one using c++ code. Moreover, if a three-diagonal array is an input, the coveted results must be something like that as;For this, the course of action is briefed in the algorithm as follows;AlgorithmStep-1: Input ... Read More

Toggle all characters in the string in C++

Ajay yadav

Ajay yadav

Updated on 29-Nov-2019 10:38:12

734 Views

This program translates the characters of a string into uppercase. However, this task can be easily achieved by using the toUpper() method of the c++ class library. But in this program, we perform this by calculating the ASCII value of characters in uppercase. The Algorithm is as follows;AlgorithmSTART    Step-1: ... Read More

Write a program for Happy Woman’s Day in c++

Ajay yadav

Ajay yadav

Updated on 29-Nov-2019 10:35:27

328 Views

The woman day which is celebrated on 7th October worldwide is carved into a c++ programming code as following;Example#include using namespace std; int main(){    // Initializing size of    // design    int n = 5;    // Loop to print Circle    // (Upper part of design) ... Read More

Advertisements