C++ Program to Implement the Monoalphabetic Cipher

This is a C++ Program to implement monoalphaetic cipher. In cryptography, a substitution cipher is a method of encoding by which units of plaintext are replaced with ciphertext, according to a regular system; the “units” may be single letters (the most common), pairs of letters, triplets of letters, mixtures of the above, and so forth. … Read more

advertisement

C++ Program to Implement Levenshtein Distance Computing Algorithm

This is a C++ Program to find Levenshtein Distance. The Wagner–Fischer algorithm is a dynamic programming algorithm that measures the Levenshtein distance between two strings of characters. For example, the Levenshtein distance between “kitten” and “sitting” is 3, since the following three edits change one into the other, and there is no way to do … Read more

advertisement

C++ Program to Find the Longest Increasing Subsequence

This is a C++ Program to implement LCS. The longest common subsequence (LCS) problem is to find the longest subsequence common to all sequences in a set of sequences (often just two). (Note that a subsequence is different from a substring, for the terms of the former need not be consecutive terms of the original … Read more

advertisement

C++ Program to Implement the Hill Cipher

This is a C++ Program to implement hill cipher. In classical cryptography, the Hill cipher is a polygraphic substitution cipher based on linear algebra. Invented by Lester S. Hill in 1929, it was the first polygraphic cipher in which it was practical (though barely) to operate on more than three symbols at once. The following … Read more

advertisement

C++ Program to Implement Grep, Egrep and Fgrep Commands

This is a C++ Program to implement grep linux command. Here is source code of the C++ Program to Implement the Program Used in grep/egrep/fgrep. The C++ program is successfully compiled and run on a Linux system. The program output is also shown below. #include<stdio.h>#include<dirent.h>int main(){ char fn[10], pat[10], temp[200]; FILE *fp; printf("\n Enter file … Read more

advertisement

C++ Program to Implement the RSA Algorithm

This C++ program encodes any message using RSA Algorithm. Input is case sensitive and works only for all characters. RSA is one of the first practicable public-key cryptosystems and is widely used for secure data transmission. In such a cryptosystem, the encryption key is public and differs from the decryption key which is kept secret. … Read more

advertisement

C++ Program to Perform Naive String Matching

This is a C++ Program to perform Naive String matching algorithm. In computer science, string searching algorithms, sometimes called string matching algorithms, are an important class of string algorithms that try to find a place where one or several strings (also called patterns) are found within a larger string or text. Here is source code … Read more

advertisement

C++ Program to Implement Longest Prefix Matching

This C++ Program demonstrates the implementation of Longest Prefix Matching. Here is source code of the C++ Program to demonstrate the implementation of Longest Prefix Matching. The C++ program is successfully compiled and run on a Linux system. The program output is also shown below. /*  * C++ Program to Implement Longest Prefix Matching */#include<iostream>#include<cstdlib>#include<cstring>#include<stack>using namespace … Read more

advertisement

C++ Program to Print All Permutations using BackTracking

This C++ Program demonstrates the generation of all Permutations using BackTracking. Here is source code of the C++ Program to Generate All Permutations using BackTracking. The C++ program is successfully compiled and run on a Linux system. The program output is also shown below. /* * C++ Program to Generate All Permutations using BackTracking */#include <iostream>#include <cstdio>#include … Read more

advertisement

Palindrome Partitioning Problem in C++

This C++ Program Solves Palindrome Partitioning Problem. Here is source code of the C++ Program to solve Palindrome Partitioning Problem. The C++ program is successfully compiled and run on a Linux system. The program output is also shown below. /* * C++ Program to Solve Palindrome Partitioning Problem */#include <iostream>#include <cstdio>#include <cstring>#include <climits>#include <cstring>#include <cstdlib>using namespace std; // … Read more

advertisement
Subscribe to our Newsletters (Subject-wise). Participate in the Sanfoundry Certification contest to get free Certificate of Merit. Join our social networks below and stay updated with latest contests, videos, internships and jobs!

Youtube | Telegram | LinkedIn | Instagram | Facebook | Twitter | Pinterest
Manish Bhojasia - Founder & CTO at Sanfoundry
Manish Bhojasia, a technology veteran with 20+ years @ Cisco & Wipro, is Founder and CTO at Sanfoundry. He lives in Bangalore, and focuses on development of Linux Kernel, SAN Technologies, Advanced C, Data Structures & Alogrithms. Stay connected with him at LinkedIn.

Subscribe to his free Masterclasses at Youtube & discussions at Telegram SanfoundryClasses.