Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
C++ Articles - Page 475 of 719
13K+ Views
Doxygen is the de facto regular tool for generating documentation from annotated C++ sources, however, it additionally supports different wellknown programming languages akin to C, objective-C, C#, Hypertext Preprocessor, Java, Python, IDL (Corba, Microsoft, and UNO/OpenOffice flavors), Fortran, VHDL and Tcl. This article explains about-“how to install Doxygen on Ubuntu”To install Doxygen, use the following command –$ sudo apt-get install doxygenThe sample output should be like this –Reading package lists... Done Building dependency tree Reading state information... Done The following packages were automatically installed and are no longer required: libterm-readkey-perl linux-headers-4.4.0-31 linux-headers-4.4.0-31-generic linux-image-4.4.0-31-generic linux-image-extra-4.4.0-31-generic linux-signed-image-4.4.0-31-generic Use 'sudo ... Read More
331 Views
Given with an array and the task is to find the number of odd and even elements in an array using standard template library in C++.To solve this problem we are using the function count_if() present in C++ standard template library. What is a count_if() function?Syntaxcount_if(LowerBound, UpperBound, function)Description − This function returns the number of elements in an array that satisfies the given condition. It takes three parameters.Lower Bound − It points to the first element of an array or any other sequence.Upper Bound − It points to the last element of an array or any other sequence.Function − It ... Read More
259 Views
Given with an array and the task is to find the number which are divisible by N using standard template library in C++.To solve this problem we are using the function count_if() present in C++ standard template library.What is a count_if() function?Syntaxcount_if(LowerBound, UpperBound, function)Description − This function returns the number of elements in an array that satisfies the given condition. It takes three parameters.Lower Bound − It points to the first element of an array or any other sequence.Upper Bound − It points to the last element of an array or any other sequence.Function − It returns the Boolean value ... Read More
366 Views
Isprint() in C++ is inbuilt function in “cctype.h” header file which checks whether the character is printable or not.Isprint returns true for constant cases as Isprint aside from the house character (' '), that returns true.A locale-specific model version of this function (Isprint) exists in cctype header file.-Isprint() function can be used to check any Non-Printing character in a series of sentences.-Isprint() is an Inbuilt function that provides efficient way to handle non printing characters-Isprint() helps to minimize the lines of code for programmer.-Isprint() is in true sense decreases the compilation time of program.Including cctype.h in your program not only ... Read More
217 Views
Given is the task to show the working of forward_list::emplace_after() and forward_list::emplace_front() functions in c++.A forward_list only keeps linkage with the next element unlike normal list that keeps linkage with the next as well as the preceding elements, which helps iterations in both directions. But forward_list can only iterate in the forward direction.The forward_list::emplace_after() and forward_list::emplace_front() functions are a part of the c++ standard library.The forward_list::emplace_after() function is used to insert a new element inside a list after the element whose position is specified inside the argumentThe forward_list::emplace_front() function is used to insert an element in the beginning of the ... Read More
134 Views
Given is the task to show the working of forward_list::cbefore_begin() function in C++.A forward_list only keeps linkage with the next element unlike normal list that keeps linkage with the next as well as the preceding elements, which helps iterations in both directions. But forward_list can only iterate in the forward direction.The forward_list::cbefore_begin() function is a part of the C++ standard template library. It is used to obtain the position before the first element of the list. header file should be included to call this function.SyntaxForward_List_Name.cbefore_begin();ParametersThe function does not accept any parameter.Return ValueThe function returns a constant iterator that points at ... Read More
182 Views
Given is the task to show the working of forward_list::cend functions in C++.A forward_list only keeps linkage with the next element unlike normal list that keeps linkage with the next as well as the preceding elements, which helps iterations in both directions. But forward_list can only iterate in the forward direction.The forward_list::cend() function is a part of the C++ standard template library. It is used to obtain the last element of the list. header file should be included to call this function.SyntaxForward_List_Name.cend();ParametersThe function does not accept any parameter.Return ValueThe function returns a constant iterator that points at the last element ... Read More
119 Views
Given is the task to show the working of forward_list::cbegin() function in C++.A forward_list only keeps linkage with the next element unlike normal list that keeps linkage with the next as well as the preceding elements, which helps iterations in both directions. But forward_list can only iterate in the forward direction.The forward_list::cbegin() function is a part of the C++ standard template library. It is used to obtain the very first element of the list. header file should be included to call the function.SyntaxForward_List_Name.cbegin();ParametersThe function does not accept any parameter.Return ValueThe function returns a constant iterator that point at the first ... Read More
294 Views
Given is the task to show the working of forward_list assign() function in C++.A forward_list only keeps linkage with the next element unlike normal list that keeps linkage with the next as well as the preceding elements, which helps iterations in forward as well as backward directions. But forward_list can only iterate in the forward direction.The forward_list::assign() function is a part of the C++ standard template library. It is used to insert elements inside a forward list and if the list already contains some elements then they are replaced by the new ones that are added by the user. header ... Read More
196 Views
We have two arrays, the task is to compare the two arrays and find the numbers present in first array but not in the second array, using Standard Template Library (STL) in C++.ExampleInput: array1[ ] = {1, 2, 3, 4, 5, 7} array2[ ] = {2, 3, 4, 5, 6, 8} Output: 1, 7 Input: array1[ ] = {1, 20, 33, 45, 67} array2[ ] = {1, 12, 13, 114, 15, 13} Output: 20, 33, 45, 67Approach used in the below program is as follows −In this program we want to find the elements which are present in the first ... Read More