C++C++11C++14C++17Code SnippetIntroduction to C++Language FeatureLearn C++

Learn To Use Powerful Modern Linked Lists In C++

Can I use linked lists with unique_ptr in a modern way? How can I use linked list with the class, struct combinations? How can I use smart pointer with linked lists? Let’s try to answer these questions. What does the smart pointer unique_ptr mean? std::unique_ptr is a smart pointer (Since C++11) that manages and owns another object with a pointer. When the unique_ptr goes out of scope…
Read more
C++Code SnippetGeneric ProgrammingLanguage FeatureLearn C++

Quickly Learn To Check OS Platform Compiled In C++ Builder With Predefined Macros

Sometimes it is needed to understand compilation platform during compile or acting and designing UI elements in accordance with the platform. In this post we would like to give some examples to check some options in application codes. The C++ compiler predefines certain global identifiers, known as manifest constants. Most global identifiers begin and end with __ (two underscores) in C++.
Read more
C++C++11C++14C++17Code SnippetLearn C++

Quickly Learn To Sort Vectors With Parallel STL Algorithm In C++ On Windows

In C++, STL Standard Template Library has many algorithms for some operations like searching, counting, and manipulation of ranges and their elements. C++17 has a new feature that you can sort vectors with Parallel STL Algorithm. In C++ Builder, Vectors can be used and sorted by Parallel STL Algorithm as below. #include <vcl.h> #include <stdio.h> #include <vector> #include…
Read more
C++C++11C++14C++17Code SnippetLearn C++

Learn To Use Powerful Lambda Expressions In C++ On Windows

Lambda Expressionsare an expression that returns a function object, it comes with C++11 standards and used C++14, C++17, C++20 standards, it is well explainedhere. Lambda expressions are widely used in C++, C#, Groovy, Java, Python, Ruby languages too. The Greek letter Lambda (λ) refers to an anonymous function, it means chosen since it is equated with something nameless and…
Read more