Category Archives: C++
C++ || Snippet – How To Use Fork & Pipe For Interprocess Communication
The following is sample code which demonstrates the use of the fork, read, and write function calls for use with pipes on
C++ || Snippet – How To Use Fork & Execlp For Interprocess Communication
The following is sample code which demonstrates the use of the “fork” and “execlp” function calls on Unix based systems. The “fork”
C++ || Snippet – Simple Timer Class Using The Clock Function
The following is sample code for a simple timer class using the “clock()” function. The “clock” function returns the processor time that
C++ || Snippet – Custom “Shuffle” Function For Arrays
The following is a custom “Shuffle” function which shuffles the contents of an array. This function rearranges each item within the array
C++ || Snippet – Custom “For Each” Iterator Function For Arrays
A “For Each” algorithm is a function that iterates over all the elements contained in a storage collection, and calls a separate
C++ || Custom Template Hash Map With Iterator Using Separate Chaining
Before we get into the code, what is a Hash Map? Simply put, a Hash Map is an extension of a Hash
C++ || Snippet – How To Display The Current Working Directory
The following is sample code which demonstrates how to display the current working directory of the program when its properties were initialized.
C++ || Snippet – How To Convert A Decimal Number Into Binary
This page will demonstrate how to convert a decimal number (i.e a whole number) into its binary equivalent. So for example, if
C++ || Custom Template Hash Table With Iterator Using Separate Chaining
Looking for sample code for a Hash Map? Click here! Before we get into the code, what is a Hash Table? Simply
C++ || Snippet – Simple Linked List Using Delete, Insert, & Display Functions
The following is sample code for a simple linked list, which implements the following functions: “Delete, Insert, and Display.” The sample code
C++ || Snippet – Custom Template Linked List Sample Code
This page will consist of sample code for a singly linked list, which is loosely based on the built in C++ “List”
C++ || Snippet – How To Swap Two Numbers Without Using A Third “Temporary” Variable
The following are three programs which demonstrates how to swap two numbers without using a third “temporary” variable. Why would anyone want
C++ || Snippet – Palindrome Checker Using A Stack & Queue
Click Here For Updated Version Of Program This page consists of a sample program which demonstrates how to use a stack
C++ || Snippet – Singly Linked List Custom Template Queue Sample Code
This page will consist of sample code for a custom singly linked list template queue. This implementation differs from the previously highlighted