Convert String to Palindrome by Changing One Character in C++

Ayush Gupta
Updated on 22-Jan-2020 07:42:15

413 Views

In this tutorial, we will be discussing a program to convert the string into palindrome string by changing only one character.For this we will be provided with a string. Our task is to convert the given string into a palindrome by changing only one character.Example Live Demo#include using namespace std; //checking if conversion to palindrome //is possible bool if_palindrome(string str){    int n = str.length();    //counting number of characters    //to be changed    int count = 0;    for (int i = 0; i < n/2; ++i)       if (str[i] != str[n - i - 1])          ++count;    return (count

Install VMware Player 7.1.2 on Ubuntu Linux Mint

Sharon Christine
Updated on 22-Jan-2020 07:40:07

383 Views

VMware Workstation Player is a streamlined desktop virtualization application that runs one or more operating systems on the same computer without rebooting. Using VMware, we can easily interact and exchange data between applications running on the virtual machine and the desktop. It supports hundreds of guest operating systems weather it may be new or old. This article describes “how to install VMware Player on Ubuntu”.Installing VMwareTo install VMware, Linux essential headers is required. For this, use the following command to install Linux essentials headers –# sudo apt-get install build-essential linux-headers-`uname -r`The sample output should be like this –Reading package lists... ... Read More

It's Time for an Upgrade

Samual Sam
Updated on 22-Jan-2020 07:40:03

197 Views

ISO standards and certifications are in the market since few decades now. They have made a significant impact on the industries and has created their own stand. They are now a synonym for an effective Quality-measuring tool. With due course of time, the ISO standards have been improved and are in accord with the current trends. High-LevelStructure of ISO has seen a complete revamp to accommodate the need for an Integrated Management System (IMS).Need for IMSAn organization usually opts for more than one certification, due to need to remain in the competition and for better business opportunities. It was observed ... Read More

Convert ASCII Value Sentence to Equivalent String in C++

Ayush Gupta
Updated on 22-Jan-2020 07:35:38

864 Views

In this tutorial, we will be discussing a program to convert the ASCII value sentence to its equivalent string.For this we will be provided with a string containing the ASCII codes. Our task is to convert the given string into the equivalent characters and print it back.Example Live Demo#include using namespace std; //converting the ASCII sequence into //character string void convert_ASCII(string str, int len){    int num = 0;    for (int i = 0; i < len; i++) {       //appending the current digit       num = num * 10 + (str[i] - '0');       //checking if number is within range       if (num >= 32 && num

Key Technology Trends in 2017

Samual Sam
Updated on 22-Jan-2020 07:35:21

260 Views

Every year the growth rate of information and technology sector is in the faster phase. 2016 was one of the major accelerators for the growth of the sector. There were few challenges for the companies with existing technologies and upcoming technologies. Beyond the challenges, few technologies remained at the top and will continue to be in the top list in the upcoming year 2017 too. Let’s see what are the technologies which are going to be the boom in the year 2017 and what are the changes which are going to happen in the existing technology.Cloud ComputingFor the past 5+ ... Read More

Install Taskwarrior: Terminal-Based To-Do Application

Sharon Christine
Updated on 22-Jan-2020 07:33:21

282 Views

Taskwarrior is an open-source, cross-platform time and task management tool. It has a command-line interface rather than a graphical user interface. If you spend a lot of time on Linux terminal (as a developer or system administrator) then constantly switching to a web app or another GUI based todo applications may not be a very productive thing to do. In that case, you may want to try a simple command line application instead. This article explains How to install Taskwarrior in Ubuntu.To install Taskwarrior, use the following command –$ sudo apt-get install taskThe sample output should be like this –Building ... Read More

Convert Array to Achieve GCD of 1 in C++

Ayush Gupta
Updated on 22-Jan-2020 07:28:31

284 Views

In this tutorial, we will be discussing a program to convert the array such that the GCD of the array becomes one.For this we will be provided with an array and a positive integer k. Our task is to convert the array elements such that the GCD of elements is 1 while only dividing the array elements by k any number of times until the element is less than k.Example Live Demo#include using namespace std; //calculating the GCD of array int calculate_gcd(int* arr, int n){    int gcd = arr[0];    for (int i = 1; i < n; i++) ... Read More

Install Subversion Server on Ubuntu 16.04

Sharon Christine
Updated on 22-Jan-2020 07:26:06

475 Views

Subversion is a free/open supply variation manipulate process (VCS). That is, Subversion manages records and directories, and the alterations made to them, over time. This makes it possible for you to get better and older models of your information or evaluate the historical past of how your data is modified. On this regard, many people suppose of a variation to manage procedure as a variety of “time computing device.”Before installing subversion, it should require apache. To install apache, use the following commands-$ sudo apt-get update $ sudo apt-get install apache2To get more information about apache installation, read this articleTo install ... Read More

Laptop Updates for January 2016

Samual Sam
Updated on 22-Jan-2020 07:23:11

139 Views

January 2016 has seen a lot of releases in the laptop arena that left the markets not only surprised but also crowded. Some of them have been setting new trends, while others are retaining the sales in the market. All in all, let us have a look at some of the best devices that are being listed in the trending gadgets currently.Asus Zenbook UX305 – Budget Friendly ?Weighing only 1.2Kg, it is easy to carry anywhere you go, and will never feel the burden. Lightweight always is seen along with a lot ofLightweight always is seen along with a lot ... Read More

Convert Ternary Expression to Binary Tree in C++

Ayush Gupta
Updated on 22-Jan-2020 07:23:09

286 Views

In this tutorial, we will be discussing a program to convert ternary expression to a binary tree.For this we will be provided with a ternary expression. Our task is to convert the given expression in the form of a binary tree depending upon the various paths(choices) possible.Example Live Demo#include using namespace std; //node structure of tree struct Node {    char data;    Node *left, *right; }; //creation of new node Node *newNode(char Data){    Node *new_node = new Node;    new_node->data = Data;    new_node->left = new_node->right = NULL;    return new_node; } //converting ternary expression into binary tree Node ... Read More

Advertisements