We are committed to provide service 24 X 7

Deals, Shopping, Training, Tools

Tag: examples

POSIX : Detached vs Joinable threads | pthread_join() & pthread_detach() examples

With every thread some resources are associated like stack and thread local storage etc.  When a thread exits ideally these resources should be reclaimed by process automatically. But that doesn’t happens always. It depends on which mode thread is running. A Thread can run in two modes i.e. Joinable Mode Detached Mode Joinable Thread & pthread_join() …

POSIX : Detached vs Joinable threads | pthread_join() & pthread_detach() examplesRead More

C++11 Smart Pointer – Part 6 : unique_ptr Tutorial and Examples

In this article we will discuss a Smart Pointer implementationstd::unique_ptr<> provided by c++11. what is std::unique_ptr ? unique_ptr<> is one of the Smart pointer implementation provided by c++11 to prevent memory leaks. A unique_ptr object wraps around a raw pointer and its responsible for its lifetime. When this object is destructed then in its destructor it deletes …

C++11 Smart Pointer – Part 6 : unique_ptr Tutorial and ExamplesRead More

Need of Operator Overloading in C++ ? | Tutorial and Examples

In this article we will discuss what is operator overloading in C++, why do we need it and how to overload an operator for a user defined class. What is Operator overloading ? Operator Overloading means providing multiple definition for the same operator. Advertisements For example, using + operator with two integers will add the …

Need of Operator Overloading in C++ ? | Tutorial and ExamplesRead More

Python : How to Sort a list of strings ? | list.sort() Tutorial & Examples

In this article we will discuss how to sort a list of string by, By Alphabetical Order By Reverse Alphabetical Order By String Length By Numeric Order list.sort() list provides a member function sort(). It Sorts the elements of list in low to high order i.e. if list is of numbers then by default they will …

Python : How to Sort a list of strings ? | list.sort() Tutorial & ExamplesRead More

C++ : How to insert element in vector at specific position | vector::insert() examples

In this article we will discuss how to insert one or multiple elements at specific index in vector. Vector provides different overloaded version of member function insert() , to insert one or more elements in between existing elements. Let’s discuss them in detail, Advertisements Inserting a single element at specific position in vector We are …

C++ : How to insert element in vector at specific position | vector::insert() examplesRead More

C++11 / C++14 : ‘delete’ keyword and deleted functions with Use Cases | Examples

In this article we will discuss how to use delete keyword with functions and its use cases. Deleting Functions using ‘delete’ keyword In C++11 a new feature of keyword delete is introduced. Now we can apply the delete keyword to functions to make them uncallable. void someFunction() = delete ; Its practical use cases are, …

C++11 / C++14 : ‘delete’ keyword and deleted functions with Use Cases | ExamplesRead More

Why do we need Lambda functions in Python ? | Explained with examples.

In this article we will discuss what is a lambda function in python and why they are required. Basically what are the use cases which makes use of lambda function must. What is a lambda function ? Lambda functions are also called Anonymous functions because they don’t have any name. Also they can be assigned …

Why do we need Lambda functions in Python ? | Explained with examples.Read More

8
206.897,50