Find two numbers whose sum is equal to a given number in sorted array

Find two numbers whose sum is equal to a given number in sorted array In order to find the sum of the two array elements you need to traverse in array and check the sum of each element. Let’s take an example of below sorted array in which we have to perform below iteration to find the sum of the array element. [1, 5, 6, 8, 10] First Iteration: 1 51 61 81 10 Second Iteration:5 65 85 10…

Read More
Reverse String in Python using Recursion

Reverse String in Python using Recursion

Let’s understand what is the recursion in programming with reverse string in Python program Recursion is a process by which a function calls itself directly or indirectly. The corresponding function is called as recursive function When Should I use Recursion ? Recursion is made for solving problems that can be broken down into smaller, repetitive problems. It is especially…

Read More
HDFS Cheat Sheet

HDFS Cheat Sheet

List of commands which I use day to day basis to perform my task in HDFS. Checkout below hdfs cheat sheet for reference. In below list I have covered Copy, Move, Check file/directory size, Change ownership of file/group, delete the files and directories etc. HDFS Cheat Sheet hdfs dfs -ls / list of all files…

Read More
Install Elasticsearch on Centos 7

Install Elasticsearch on Centos 7

Steps to Install Elasticsearch on centos 7 Prerequisites: Install OpenJDK 8 version sudo yum install java-1.8.0-openjdk.x86_64 Validate the installation java -version If you are installing jdk manually from tar file then make sure if you have configure the JAVA_HOME path correctly. Install Elasticsearch Latest version using Yum. Import the Elasticsearch GPG Key rpm –import https://artifacts.elastic.co/GPG-KEY-elasticsearch…

Read More
Verified by MonsterInsights