Sunidhi Bansal has Published 1100 Articles

Different ways to declare variable as constant in C and C++

Sunidhi Bansal

Sunidhi Bansal

Updated on 14-Aug-2020 08:40:57

653 Views

There are multiple ways of declaring constants in C and C++. First of all, we need to understand what constant is.What is a Constant?Constant means which can’t be changed. In terms of programming, constants are the fixed values that are assigned to the variables such that they can’t be altered ... Read More

Upper bound and Lower bound for non increasing vector in C++

Sunidhi Bansal

Sunidhi Bansal

Updated on 14-Aug-2020 08:31:50

4K+ Views

In this article we are going to discuss the vector::upper_bound() and vector::lower_bound() for an array sorted in non-increasing order in C++ STL.Vectors are similar to the dynamic arrays; they have the ability to modify its size itself whenever a value is inserted into or removed from the container where we ... Read More

map count( ) function in C++

Sunidhi Bansal

Sunidhi Bansal

Updated on 14-Aug-2020 08:29:37

4K+ Views

In this article we will be discussing the working, syntax and examples of map::empty() function in C++ STL.What is Map in C++ STL?Maps are the associative container, which facilitates to store the elements formed by a combination on key value and mapped value in a specific order. In a map ... Read More

Sin( ) function for complex number in C++

Sunidhi Bansal

Sunidhi Bansal

Updated on 14-Aug-2020 08:27:16

115 Views

We are given with the task to find the working of sin() function for complex number. The sin( ) function for complex numbers are present in the complex header file which means for calculating the value of sin() we need to add the complex header file in the code. In ... Read More

Sinh( ) function for complex number in C++

Sunidhi Bansal

Sunidhi Bansal

Updated on 14-Aug-2020 08:25:45

100 Views

We are given with the task to find the working of sin() function for complex number. The sin( ) function for complex numbers are present in the complex header file which means for calculating the value of sin() we need to add the complex header file in the code. This ... Read More

map max_size() in C++ STL

Sunidhi Bansal

Sunidhi Bansal

Updated on 14-Aug-2020 08:24:33

1K+ Views

In this article we will be discussing the working, syntax and examples of map::max_size() function in C++ STL.What is a Map in C++ STL?Maps are the associative container, which facilitates to store the elements formed by a combination of key value and mapped value in a specific order. In a ... Read More

map::operator[] in C++ STL Program

Sunidhi Bansal

Sunidhi Bansal

Updated on 14-Aug-2020 08:23:02

362 Views

In this article we will be discussing the working, syntax and example of map equal ‘[]’ operator in C++ STL.What is a Map in C++ STL?Maps are the associative container, which facilitates to store the elements formed by a combination of key value and mapped value in a specific order. ... Read More

iswprint( ) in C++

Sunidhi Bansal

Sunidhi Bansal

Updated on 14-Aug-2020 08:18:19

36 Views

We are given with the task to show the working of iswprint( ). The iswprint( ) function in C++ STL is used to check that whether the given wide character can be printed or not. It is a function present in cwctype header file in C++. Wide characters is a ... Read More

Split the sentence into words in C++

Sunidhi Bansal

Sunidhi Bansal

Updated on 14-Aug-2020 08:14:52

1K+ Views

Given is the task to split the sentence into words. In this, we will separate all the words present in sentence.Input I am a good boyOutput I am a good boyIn the above example we will print the single word in single line.Example#include #include #include Using namespace std; void split( string st){ ... Read More

sqrt ( ) function for complex number in C++

Sunidhi Bansal

Sunidhi Bansal

Updated on 14-Aug-2020 08:09:49

380 Views

Given is the task to find the working of sqrt() function for complex number. Basically the sqrt( ) is a function present in complex header file. This function is used to calculate the square root of complex number.Syntaxtemplate complex Sqrt(const complex& x);Parameterx − This parameter x which represent the complex ... Read More

Advertisements