Tip 1 : Practice coding from Leetcode, Interview bit, at least 100 questions
Tip 2 : Practice any one automation framework includes design patterns
Tip 1 : Restrict your resume to 1 page and write your practical work only
Tip 2 : Mention top topics like Selenium, Rest Assured Automation, Language used Java etc



You are given an array of N integers and an integer K. For each array element, you are allowed to increase or decrease it by a value k. The task is to minimize the difference between the maximum element and the minimum element after modifications.
Input Format :
The first line of input contains a single integer T, representing the number of test cases or queries to be run.
Then the test cases follow.
The first line of each test case contains a positive integer N which represents the number of elements of an array.
The Second line of each test case contains N integers denoting the elements of the array.
The third line of each test case contains a positive integer K.



You are given the arrival and departure times of N trains at a railway station in a day. You need to find the minimum of platforms required for the railway station such that no train waits i.e No train should wait for the platform to be clear or free.
Input Format :
The first line of input contains a single integer T, representing the number of test cases or queries to be run.
Then the T test cases follow.
The first line of each test case contains a positive integer N which represents the number of trains that arrive at the railway station in a day.
The Second line of each test case contains N integers denoting the arrival time of all the trains.
The third line of each test case contains N integers denoting the departure time of all the trains.



You must sell the stock before you buy it again.
You are given an array(PRICES) of stock prices for N consecutive days. Your task is to find the maximum profit that you can make by completing as many transactions as you like, where a transaction denotes buying one and selling one share of the stock.



Type 1: Two Wheeler Road, It means only vehicles having two wheels can use this road.
Type 2: Four Wheeler Road, It means only vehicles having four wheels can use this road.
Type 3: Both two and four Wheeler Road, It means this road can be used by both type of vehicles.
1. Roads may form a cycle.
2. The cities do not have multiple same roads i.e all the roads are unique.
3. If every city cannot be reached, then return -1.
There is a country with 'N' cities and 'M' bidirectional roads of 3 types.
Type 1: Two Wheeler Road, It means only vehicles having two wheels can use this road.
Type 2: Four Wheeler Road, It means only vehicles having four wheels can use this road.
Type 3: Both two and four Wheeler Road, It means this road can be used by both type of vehicles.
The problem is to find the maximum number of roads that can be removed such that a path exists for every pair of cities for each two-wheeler and four-wheeler vehicle.
Note:
1. Roads may form a cycle.
2. The cities do not have multiple same roads i.e all the roads are unique.
3. If every city cannot be reached, then return -1.

Here's your problem of the day
Solving this problem will increase your chance to get selected in this company
What is recursion?