## TCS Coding Practice Question | Reverse a Number

Given a number, the task is to reverse this number using Command Line Arguments. Examples: Input: num = 12345 Output: 54321 Input: num = 786… Read More »

## TCS Coding Practice Question | Check Palindrome Number

Given a number, the task is to check if this number is Palindrome or not using Command Line Arguments. Examples: Input: 123 Output: No Input:… Read More »

## Creating an Asynchronous Multithreaded chat Application in Java

Prerequisite: Datagrams in Java In this article, we will learn how to use Datagrams in Java to create an Asynchronous messaging application in java. Asynchronous… Read More »

## How to get the value of System Property and Environment Variable in Java?

How to get the value of Environment variables? The System class in Java provides a method named System.getenv() which can be used to get the… Read More »

## Program to unfold a folded linked list

A linked list L0 -> L1 -> L2 -> ….. -> LN can be folded as L0 -> LN -> L1 -> LN – 1… Read More »

## Sort ugly numbers in an array at their relative positions

Given an integer array arr[], the task is to sort only those elements which are ugly numbers at their relative positions in the array (positions… Read More »

## Print last character of each word in a string

Given a string str, the task is to print the last character of each word in the string. Examples: Input: str = “Geeks for Geeks”… Read More »

## Find the hypotenuse of a right angled triangle with given two sides

Given the other two sides of a right angled triangle, the task is to find it’s hypotenuse. Examples: Input: side1 = 3, side2 = 4… Read More »

## How to concatenate two Integer values into one?

Given two integers n1 and n2, the task is to concatenate these two integers into one integer. Example: Input: n1 = 12, n2 = 34… Read More »

## Program to calculate the value of nPr

Given two numbers n and r, the task is to find the value of nPr. nPr represents n permutation r which is calculated as n!/(n-k)!.… Read More »

## Check if the given array is mirror-inverse

Given an array arr[], the task is to find whether the array is mirror inverse. Inverse of an array means if the array elements are… Read More »

## Different Approaches to Concurrent Programming in Java

This article shows how to perform concurrent programming using Java threading framework. Let’s analyze concurrent programming first: Concurrent Programming: This means that tasks appear to… Read More »

## Parameter Passing Techniques in Java with Examples

There are different ways in which parameter data can be passed into and out of methods and functions. Let us assume that a function B()… Read More »

## Maximum length subarray with difference between adjacent elements as either 0 or 1

Given an array of n integers. The task is to find the maximum length of the sub-array such that absolute difference between all the consecutive… Read More »

## Java Program to print distinct permutations of a string

Given a string str, the task is to print all the distinct permutations of str. A permutation is an arrangement of all or part of… Read More »