New
Know More
New
Know More
New
Know More
View All Preparation Packages

EPAM

No of Coding Questions
Coding Questions :
16
No. of MCQ Questions
MCQ Questions :
0
No. of Mock Tests
Mock Test :
Coming Soon
Arrow leading towards next section of Landing Page

About EPAM 

EPAM Systems is a leading provider of innovative custom software and consulting services, with a strong global presence in over 30 countries. Its headquarters is based in Newtown, Pennsylvania, and it is dedicated to providing exceptional product development, digital platform engineering, and digital product design services to its clients. Its expertise and commitment to delivering real business value has established it as a trusted and reliable partner in the industry.

As a company, it believes in a holistic approach to digital innovation, integrating our expertise in software engineering with strategic business consulting, design thinking, and physical-digital solutions. Its unique approach has enabled it to help clients transform their operations and achieve real business results.

To further its commitment to excellence, it hires CSE graduates via a comprehensive EPAM exam. On this page you will find links to the study material, best practices, expert advice, and practice questions especially designed to help CSE students prepare and pass the EPAM CSE exam with confidence. Whether you're looking to brush up on your skills, gain a deeper understanding of the exam pattern and syllabus, or simply get inspired by success stories of others, we have you covered. Browse through and discover why EPAM Systems past year interview questions and answers are the best choice for preparing and passing the EPAM CSE fresher exam.

Benefits of EPAM

  1. Prepare for a career at EPAM: The exam helps candidates to prepare for a career at EPAM by enabling them to gain knowledge on live projects.
  2. Opportunities for placement: Clearing the exam increases the candidate's chances of getting placed in EPAM through on-campus or off-campus placement drives.
  3. Improved skills and knowledge: The exam helps to enhance the candidate's technical, analytical, and communication skills, preparing them for the job market.
  4. Access to EPAM network: Successful candidates become part of the EPAM network, which opens up new opportunities for career growth and professional development.
  5. Boost to resume: Clearing the EPAM Exam is a valuable addition to a candidate's resume, showcasing their aptitude and commitment to a career in the IT services industry.

Eligibility Criteria for EPAM

Eligibility criteria required to apply for the Junior Software Engineer job role:

  • Graduation Year: Candidates who graduated in 2020, 2021 & 2022 should apply.
  • Qualifications: B.E./B.Tech/M.E./M.Tech completed with specialisation in CSE/IT/ECE or any related computer science stream.
  • Practices/Technologies Offered: Opensource (JAVA), .Net, Front End Technologies (Javascript, Angular/React/Node JS), (AWS/Azure/ GCP).
  • Percentage: Applicant should have scored 60% across 10th, 12th and graduation.

Exam Pattern for EPAM

EPAM Systems' recruitment process is unique in its focus on Java language proficiency. The first round is a Java Online Coding Challenge, where candidates are required to complete 3 coding questions within 150 minutes while being monitored via webcam. The first question is worth 20 marks, the second is worth 30 marks, and the third is worth 50 marks.

The second round consists of 11 multiple-choice questions on topics such as Java, OOP, C++, DBMS, Networking, and Operating Systems, worth 20 marks. Additionally, there are 2 coding questions to be completed in 1 hour.

Arrow leading towards next section of Landing Page

EPAM Selection Process

EPAM India has a unique selection process that focuses on practical knowledge and skills, as opposed to theoretical exams. 

There will be five steps in the EPAM interview process:

  • Round 1: Online Coding Challenge (Core JAVA)
  • Round 2: Coding Challenge (Core JAVA)
  • Round 3: Group Discussion
  • Round 4: Technical Evaluation
  • Round 5: HR Interview

The first round is a coding and aptitude test conducted through the my anatomy portal. It includes questions on Java, data structures, and algorithms. The virtual round is open to all and consists of three programming problems to solve in Java only.

Selected candidates move on to the second round, which is similar to the first round but with increased difficulty. The third round is a technical interview that lasts for over an hour and covers topics such as abstract classes, interfaces, and private constructors. The interviewer also asks about the coding questions from the first and second rounds.

Finally, there is an HR interview that lasts for about 30 minutes. This is a normal conversation about the candidate's background, hobbies, and projects, as well as a discussion about the work culture at EPAM.

Arrow leading towards next section of Landing Page

Popular Questions

#Popular Question1

#Game of Profit

You’re given the predicate price of XYZ company’s share for every minute. Each minute, you’re allowed to either buy one share of XYZ or sell any number of shares of XYZ that you own or not make any transaction at all. Your task is to find out the max profit.

#Constraints:

```sh

1 <= T <= 10

1 <= N <= 5*10^5

All share price are between 1 and 10^5

```

#Sample Input:

```sh

3

3

5 3 2

3

1 2 100

4

1 3 1 2

```

#Output:

```sh

0

197

3

```

#Coding Question1 

Write an algorithm for quicksort.

#Solution:

```sh

import java.util.Arrays;

class Quicksort 

{

// method to find the partition position

 static int partition(int array[], int leftmost, int rightmost) 

{

//leftmost element as pivot

int pivot = array[rightmost];

// pointer for greater element

int i = (leftmost - 1);

// compare each element with pivot

for (int j = leftmost; j < rightmost; j++) 

{

if (array[j] <= pivot) 

{

// If element found is smaller than pivot

//it will be swapped with the larger element pointed by i

i++;

// element at i is swapped with element at j

int s = array[i];

array[i] = array[j];

array[j] = s;

}

}

// swapt the pivot element with the greater element specified by i

int s = array[i + 1];

array[i + 1] = array[rightmost];

array[rightmost] = s;

// return the position from where partition is done

return (i + 1);

}

static void quickSort(int array[], int leftmost, int rightmost) 

{

if (leftmost < rightmost) 

{

int pi = partition(array, leftmost, rightmost);

// recursive call on the left of pivot

quickSort(array, leftmost, pi - 1);

// recursive call on the right of pivot

quickSort(array, pi + 1, rightmost);

}

}

}

class Main 

{

public static void main(String args[]) 

{

int[] arr = { 5, 4, 6, 1, 0, 8, 3 };

System.out.println("Unsorted Array");

System.out.println(Arrays.toString(arr));

int size = arr.length;

Quicksort.quickSort(arr, 0, size - 1);

System.out.println("Sorted Array in Ascending Order: ");

System.out.println(Arrays.toString(arr));

}

}

```

#Output:

```sh

Unsorted Array

[5, 4, 6, 1, 0, 8, 3]

Sorted Array in Ascending Order: 

[0, 1, 3, 4, 5, 6, 8]

```

#Popular Question2

#Student for Viva

The seasons of the vivas are ON!! There are a number of students in a class. Each class of students has to give viva, but there is one rule teacher has decided to choose the student whose turn it will give viva. The teacher is picking a certain role number from the list of the students. On each day, students with a high role number than his left student role number will be picked to give viva on that day. Determine the number of days after which no student from the initial picking is remaining to give viva, i.e the time after which there is no student with a higher roll number on his left.

#Example:

roll_numbers = [3, 6, 7, 5] (roll numbers of the students randomly picked initially amongst all students)

Use a 1-indexed array. On day 1, roll numbers 6 and 7 will be picked to give viva leaving roll_numbers = [3, 2, 5]. On day 2, roll numbers 5 will be picked for viva leaving roll_numbers = [3, 2]. There is no student with a higher roll number than one to its left, so that batch will be over with the viva and will be ready to enjoy the vacations.

#Constraints:

```sh

1 <= n <- 10^5

1 <= roll_number[i] <= 10^9

```

#Sample Input:

```sh

7

6 5 8 4 7 10 9

```

#Output:

```sh

2

```

#Coding Question2 

Write a program to count the number of vowels occurring in all the substrings of a given String.

#Solution:

```sh

import java.io.*;

import java.util.*;

import java.util.Scanner; 

public class Main {

//calculates total sum of all vowel occurrences

static int vowel_calc(String str)

{

int n = str.length();

int arr[] = new int[n];

for (int i = 0; i < n; i++) 

if (i == 0)

// Number of times the 0th character occurs in all substrings

arr[i] = n; 

else

// Number of times the ith character occurs in all substrings

arr[i] = (n - i) + arr[i - 1] - i;

}

int sum = 0;

for (int i = 0; i < n; i++) {

char ch = str.charAt(i);

// Check to see if ith character is a vowel

if (ch == 'a' || ch == 'e' || ch == 'i' || ch == 'o' || ch == 'u')

sum += arr[i];

}

// Return total sum of all vowel occurrences      

return sum;

}

// Driver Code

public static void main(String args[])

{

Scanner sc= new Scanner(System.in); 

System.out.println("Enter a String");

String str=sc.nextLine();

System.out.println(vowel_calc(str));

}

}

```

#Output:

```sh

Enter a String

Scaler

22

```

#Popular Question3

#Oxygen Cylinders Management

You’ve given a list of covid patients where patient[i] is the required by the ith patient, and there are enough cylinders where each cylinder contains a limited amount of oxygen. Each cylinder can serve at most two patients at the same time, provided the array of the oxygen required by the patients and cylinder capacity. Return the minimum quantity of cylinders to serve all patients.

#Constraints:

```sh

1 <= n <=10000

1 <= patients[i] <= limit <=3 * 10000

```

#Sample Input:

```sh

2

1

1

2

```

#Sample Output:

```sh

1

```

#Coding Question3

Print ASCII Value in Java

#Solution:

```sh

public class PrintAsciiValueExample1   

{  

public static void main(String[] args)   

{  

// character whose ASCII value to be found  

char ch1 = 'a';  

char ch2 = 'b';  

// variable that stores the integer value of the character  

int asciivalue1 = ch1;  

int asciivalue2 = ch2;  

System.out.println("The ASCII value of " + ch1 + " is: " + asciivalue1);  

System.out.println("The ASCII value of " + ch2 + " is: " + asciivalue2);  

}  

}  

```

#Output:

```sh

The ASCII value of a is: 97

The ASCII value of b is: 98

```

#Coding Question4

Write a Java Program to Display Alternate Prime Numbers


#Solution

```sh

import java.util.Scanner;

class AlternatePrimeNumbers {

public static void main(String[] args) {

Scanner input = new Scanner(System.in);

System.out.print("Enter the range: ");

int range = input.nextInt();

input.close();

boolean isPrime;

int counter = 0;

System.out.println("Alternate Prime Numbers: ");

for (int num = 2; num <= range; num++) {

isPrime = true;

for (int i = 2; i <= num / 2; i++) {

if (num % i == 0) {

isPrime = false;

break;

}

}

if (isPrime) {

counter++;

if (counter % 2 == 0) {

System.out.print(num + " ");

}

}

}

}

}

```

#Coding Question5

Write a Java Program to find Third Largest Number in an Array


#Solution

```sh

public class ThirdLargestInArrayExample{  

public static int getThirdLargest(int[] a, int total){  

int temp;  

for (int i = 0; i < total; i++)   

{  

for (int j = i + 1; j < total; j++)   

{  

if (a[i] > a[j])   

{  

temp = a[i];  

a[i] = a[j];  

a[j] = temp;  

}  

}  

}  

return a[total-3];  

}  

public static void main(String args[]){  

int a[]={1,2,5,6,3,2};  

int b[]={44,66,99,77,33,22,55};  

System.out.println("Third Largest: "+getThirdLargest(a,6));  

System.out.println("Third Largest: "+getThirdLargest(b,7));  

}}  

```

#Output:

```sh

Third Largest:3

Third Largest:66

```

Previously Asked Question

#Popular Question1

#Game of Profit

You’re given the predicate price of XYZ company’s share for every minute. Each minute, you’re allowed to either buy one share of XYZ or sell any number of shares of XYZ that you own or not make any transaction at all. Your task is to find out the max profit.

#Constraints:

```sh

1 <= T <= 10

1 <= N <= 5*10^5

All share price are between 1 and 10^5

```

#Sample Input:

```sh

3

3

5 3 2

3

1 2 100

4

1 3 1 2

```

#Output:

```sh

0

197

3

```

#Coding Question1 

Write an algorithm for quicksort.

#Solution:

```sh

import java.util.Arrays;

class Quicksort 

{

// method to find the partition position

 static int partition(int array[], int leftmost, int rightmost) 

{

//leftmost element as pivot

int pivot = array[rightmost];

// pointer for greater element

int i = (leftmost - 1);

// compare each element with pivot

for (int j = leftmost; j < rightmost; j++) 

{

if (array[j] <= pivot) 

{

// If element found is smaller than pivot

//it will be swapped with the larger element pointed by i

i++;

// element at i is swapped with element at j

int s = array[i];

array[i] = array[j];

array[j] = s;

}

}

// swapt the pivot element with the greater element specified by i

int s = array[i + 1];

array[i + 1] = array[rightmost];

array[rightmost] = s;

// return the position from where partition is done

return (i + 1);

}

static void quickSort(int array[], int leftmost, int rightmost) 

{

if (leftmost < rightmost) 

{

int pi = partition(array, leftmost, rightmost);

// recursive call on the left of pivot

quickSort(array, leftmost, pi - 1);

// recursive call on the right of pivot

quickSort(array, pi + 1, rightmost);

}

}

}

class Main 

{

public static void main(String args[]) 

{

int[] arr = { 5, 4, 6, 1, 0, 8, 3 };

System.out.println("Unsorted Array");

System.out.println(Arrays.toString(arr));

int size = arr.length;

Quicksort.quickSort(arr, 0, size - 1);

System.out.println("Sorted Array in Ascending Order: ");

System.out.println(Arrays.toString(arr));

}

}

```

#Output:

```sh

Unsorted Array

[5, 4, 6, 1, 0, 8, 3]

Sorted Array in Ascending Order: 

[0, 1, 3, 4, 5, 6, 8]

```

#Popular Question2

#Student for Viva

The seasons of the vivas are ON!! There are a number of students in a class. Each class of students has to give viva, but there is one rule teacher has decided to choose the student whose turn it will give viva. The teacher is picking a certain role number from the list of the students. On each day, students with a high role number than his left student role number will be picked to give viva on that day. Determine the number of days after which no student from the initial picking is remaining to give viva, i.e the time after which there is no student with a higher roll number on his left.

#Example:

roll_numbers = [3, 6, 7, 5] (roll numbers of the students randomly picked initially amongst all students)

Use a 1-indexed array. On day 1, roll numbers 6 and 7 will be picked to give viva leaving roll_numbers = [3, 2, 5]. On day 2, roll numbers 5 will be picked for viva leaving roll_numbers = [3, 2]. There is no student with a higher roll number than one to its left, so that batch will be over with the viva and will be ready to enjoy the vacations.

#Constraints:

```sh

1 <= n <- 10^5

1 <= roll_number[i] <= 10^9

```

#Sample Input:

```sh

7

6 5 8 4 7 10 9

```

#Output:

```sh

2

```

#Coding Question2 

Write a program to count the number of vowels occurring in all the substrings of a given String.

#Solution:

```sh

import java.io.*;

import java.util.*;

import java.util.Scanner; 

public class Main {

//calculates total sum of all vowel occurrences

static int vowel_calc(String str)

{

int n = str.length();

int arr[] = new int[n];

for (int i = 0; i < n; i++) 

if (i == 0)

// Number of times the 0th character occurs in all substrings

arr[i] = n; 

else

// Number of times the ith character occurs in all substrings

arr[i] = (n - i) + arr[i - 1] - i;

}

int sum = 0;

for (int i = 0; i < n; i++) {

char ch = str.charAt(i);

// Check to see if ith character is a vowel

if (ch == 'a' || ch == 'e' || ch == 'i' || ch == 'o' || ch == 'u')

sum += arr[i];

}

// Return total sum of all vowel occurrences      

return sum;

}

// Driver Code

public static void main(String args[])

{

Scanner sc= new Scanner(System.in); 

System.out.println("Enter a String");

String str=sc.nextLine();

System.out.println(vowel_calc(str));

}

}

```

#Output:

```sh

Enter a String

Scaler

22

```

#Popular Question3

#Oxygen Cylinders Management

You’ve given a list of covid patients where patient[i] is the required by the ith patient, and there are enough cylinders where each cylinder contains a limited amount of oxygen. Each cylinder can serve at most two patients at the same time, provided the array of the oxygen required by the patients and cylinder capacity. Return the minimum quantity of cylinders to serve all patients.

#Constraints:

```sh

1 <= n <=10000

1 <= patients[i] <= limit <=3 * 10000

```

#Sample Input:

```sh

2

1

1

2

```

#Sample Output:

```sh

1

```

#Coding Question3

Print ASCII Value in Java

#Solution:

```sh

public class PrintAsciiValueExample1   

{  

public static void main(String[] args)   

{  

// character whose ASCII value to be found  

char ch1 = 'a';  

char ch2 = 'b';  

// variable that stores the integer value of the character  

int asciivalue1 = ch1;  

int asciivalue2 = ch2;  

System.out.println("The ASCII value of " + ch1 + " is: " + asciivalue1);  

System.out.println("The ASCII value of " + ch2 + " is: " + asciivalue2);  

}  

}  

```

#Output:

```sh

The ASCII value of a is: 97

The ASCII value of b is: 98

```

#Coding Question4

Write a Java Program to Display Alternate Prime Numbers


#Solution

```sh

import java.util.Scanner;

class AlternatePrimeNumbers {

public static void main(String[] args) {

Scanner input = new Scanner(System.in);

System.out.print("Enter the range: ");

int range = input.nextInt();

input.close();

boolean isPrime;

int counter = 0;

System.out.println("Alternate Prime Numbers: ");

for (int num = 2; num <= range; num++) {

isPrime = true;

for (int i = 2; i <= num / 2; i++) {

if (num % i == 0) {

isPrime = false;

break;

}

}

if (isPrime) {

counter++;

if (counter % 2 == 0) {

System.out.print(num + " ");

}

}

}

}

}

```

#Coding Question5

Write a Java Program to find Third Largest Number in an Array


#Solution

```sh

public class ThirdLargestInArrayExample{  

public static int getThirdLargest(int[] a, int total){  

int temp;  

for (int i = 0; i < total; i++)   

{  

for (int j = i + 1; j < total; j++)   

{  

if (a[i] > a[j])   

{  

temp = a[i];  

a[i] = a[j];  

a[j] = temp;  

}  

}  

}  

return a[total-3];  

}  

public static void main(String args[]){  

int a[]={1,2,5,6,3,2};  

int b[]={44,66,99,77,33,22,55};  

System.out.println("Third Largest: "+getThirdLargest(a,6));  

System.out.println("Third Largest: "+getThirdLargest(b,7));  

}}  

```

#Output:

```sh

Third Largest:3

Third Largest:66

```

Testimonials

Ria

Placed in
OLX
-
20 LPA

Vaishnavi

Placed in
ServiceNow
-
24 LPA

Edyst's training style completely resonated with me. I approached programming as more than a subject. Thanks to Edyst team for the guidance!

Pruthviraj

Placed in
Futurense
-
9.5 LPA

Dileep

Placed in
TCS Digital
-
7 LPA+

Being a mechanical student and getting into an IT company is very tough. One of the main reason I could able to crack TCS CodeVita is because of Edyst.
Aneeq sir, your doubt clearing sessions, daily assignments & incredible mentors support really brushed up my skills.

Sakila

Placed in
Adobe
-
12 LPA

I started practising on Edyst platform since my 3rd year of college focused on placements & always liked the way they helped us when we were stuck at a particular problem.
Thank you, Edyst for all the assistance and amazing support!

Sriram

Placed in
Seawise Capital
-
8 LPA

When I joined the Edyst courses I received personalized mentoring on how to crack coding rounds of different companies. Through a combination of coding skills and great projects, I received multiple offers above 6+ lakhs per annum. Finally I joined for 8+ Lakhs package. Thanks for all the support, from Edyst Team.

Arrow leading towards next section of Landing Page

Coding Interview Round Sample Questions 

Here are some examples of coding interview questions that may be asked (entry-level candidates with little or no professional experience):

#Popular Question1

#Game of Profit

You’re given the predicate price of XYZ company’s share for every minute. Each minute, you’re allowed to either buy one share of XYZ or sell any number of shares of XYZ that you own or not make any transaction at all. Your task is to find out the max profit.

#Constraints:

```sh

1 <= T <= 10

1 <= N <= 5*10^5

All share price are between 1 and 10^5

```

#Sample Input:

```sh

3

3

5 3 2

3

1 2 100

4

1 3 1 2

```

#Output:

```sh

0

197

3

```

#Coding Question1 

Write an algorithm for quicksort.

#Solution:

```sh

import java.util.Arrays;

class Quicksort 

{

// method to find the partition position

 static int partition(int array[], int leftmost, int rightmost) 

{

//leftmost element as pivot

int pivot = array[rightmost];

// pointer for greater element

int i = (leftmost - 1);

// compare each element with pivot

for (int j = leftmost; j < rightmost; j++) 

{

if (array[j] <= pivot) 

{

// If element found is smaller than pivot

//it will be swapped with the larger element pointed by i

i++;

// element at i is swapped with element at j

int s = array[i];

array[i] = array[j];

array[j] = s;

}

}

// swapt the pivot element with the greater element specified by i

int s = array[i + 1];

array[i + 1] = array[rightmost];

array[rightmost] = s;

// return the position from where partition is done

return (i + 1);

}

static void quickSort(int array[], int leftmost, int rightmost) 

{

if (leftmost < rightmost) 

{

int pi = partition(array, leftmost, rightmost);

// recursive call on the left of pivot

quickSort(array, leftmost, pi - 1);

// recursive call on the right of pivot

quickSort(array, pi + 1, rightmost);

}

}

}

class Main 

{

public static void main(String args[]) 

{

int[] arr = { 5, 4, 6, 1, 0, 8, 3 };

System.out.println("Unsorted Array");

System.out.println(Arrays.toString(arr));

int size = arr.length;

Quicksort.quickSort(arr, 0, size - 1);

System.out.println("Sorted Array in Ascending Order: ");

System.out.println(Arrays.toString(arr));

}

}

```

#Output:

```sh

Unsorted Array

[5, 4, 6, 1, 0, 8, 3]

Sorted Array in Ascending Order: 

[0, 1, 3, 4, 5, 6, 8]

```

#Popular Question2

#Student for Viva

The seasons of the vivas are ON!! There are a number of students in a class. Each class of students has to give viva, but there is one rule teacher has decided to choose the student whose turn it will give viva. The teacher is picking a certain role number from the list of the students. On each day, students with a high role number than his left student role number will be picked to give viva on that day. Determine the number of days after which no student from the initial picking is remaining to give viva, i.e the time after which there is no student with a higher roll number on his left.

#Example:

roll_numbers = [3, 6, 7, 5] (roll numbers of the students randomly picked initially amongst all students)

Use a 1-indexed array. On day 1, roll numbers 6 and 7 will be picked to give viva leaving roll_numbers = [3, 2, 5]. On day 2, roll numbers 5 will be picked for viva leaving roll_numbers = [3, 2]. There is no student with a higher roll number than one to its left, so that batch will be over with the viva and will be ready to enjoy the vacations.

#Constraints:

```sh

1 <= n <- 10^5

1 <= roll_number[i] <= 10^9

```

#Sample Input:

```sh

7

6 5 8 4 7 10 9

```

#Output:

```sh

2

```

#Coding Question2 

Write a program to count the number of vowels occurring in all the substrings of a given String.

#Solution:

```sh

import java.io.*;

import java.util.*;

import java.util.Scanner; 

public class Main {

//calculates total sum of all vowel occurrences

static int vowel_calc(String str)

{

int n = str.length();

int arr[] = new int[n];

for (int i = 0; i < n; i++) 

if (i == 0)

// Number of times the 0th character occurs in all substrings

arr[i] = n; 

else

// Number of times the ith character occurs in all substrings

arr[i] = (n - i) + arr[i - 1] - i;

}

int sum = 0;

for (int i = 0; i < n; i++) {

char ch = str.charAt(i);

// Check to see if ith character is a vowel

if (ch == 'a' || ch == 'e' || ch == 'i' || ch == 'o' || ch == 'u')

sum += arr[i];

}

// Return total sum of all vowel occurrences      

return sum;

}

// Driver Code

public static void main(String args[])

{

Scanner sc= new Scanner(System.in); 

System.out.println("Enter a String");

String str=sc.nextLine();

System.out.println(vowel_calc(str));

}

}

```

#Output:

```sh

Enter a String

Scaler

22

```

#Popular Question3

#Oxygen Cylinders Management

You’ve given a list of covid patients where patient[i] is the required by the ith patient, and there are enough cylinders where each cylinder contains a limited amount of oxygen. Each cylinder can serve at most two patients at the same time, provided the array of the oxygen required by the patients and cylinder capacity. Return the minimum quantity of cylinders to serve all patients.

#Constraints:

```sh

1 <= n <=10000

1 <= patients[i] <= limit <=3 * 10000

```

#Sample Input:

```sh

2

1

1

2

```

#Sample Output:

```sh

1

```

#Coding Question3

Print ASCII Value in Java

#Solution:

```sh

public class PrintAsciiValueExample1   

{  

public static void main(String[] args)   

{  

// character whose ASCII value to be found  

char ch1 = 'a';  

char ch2 = 'b';  

// variable that stores the integer value of the character  

int asciivalue1 = ch1;  

int asciivalue2 = ch2;  

System.out.println("The ASCII value of " + ch1 + " is: " + asciivalue1);  

System.out.println("The ASCII value of " + ch2 + " is: " + asciivalue2);  

}  

}  

```

#Output:

```sh

The ASCII value of a is: 97

The ASCII value of b is: 98

```

#Coding Question4

Write a Java Program to Display Alternate Prime Numbers


#Solution

```sh

import java.util.Scanner;

class AlternatePrimeNumbers {

public static void main(String[] args) {

Scanner input = new Scanner(System.in);

System.out.print("Enter the range: ");

int range = input.nextInt();

input.close();

boolean isPrime;

int counter = 0;

System.out.println("Alternate Prime Numbers: ");

for (int num = 2; num <= range; num++) {

isPrime = true;

for (int i = 2; i <= num / 2; i++) {

if (num % i == 0) {

isPrime = false;

break;

}

}

if (isPrime) {

counter++;

if (counter % 2 == 0) {

System.out.print(num + " ");

}

}

}

}

}

```

#Coding Question5

Write a Java Program to find Third Largest Number in an Array


#Solution

```sh

public class ThirdLargestInArrayExample{  

public static int getThirdLargest(int[] a, int total){  

int temp;  

for (int i = 0; i < total; i++)   

{  

for (int j = i + 1; j < total; j++)   

{  

if (a[i] > a[j])   

{  

temp = a[i];  

a[i] = a[j];  

a[j] = temp;  

}  

}  

}  

return a[total-3];  

}  

public static void main(String args[]){  

int a[]={1,2,5,6,3,2};  

int b[]={44,66,99,77,33,22,55};  

System.out.println("Third Largest: "+getThirdLargest(a,6));  

System.out.println("Third Largest: "+getThirdLargest(b,7));  

}}  

```

#Output:

```sh

Third Largest:3

Third Largest:66

```

Dropdown Icon

#Coding Question1 

Write an algorithm for quicksort.

#Solution:

```sh

import java.util.Arrays;

class Quicksort 

{

// method to find the partition position

 static int partition(int array[], int leftmost, int rightmost) 

{

//leftmost element as pivot

int pivot = array[rightmost];

// pointer for greater element

int i = (leftmost - 1);

// compare each element with pivot

for (int j = leftmost; j < rightmost; j++) 

{

if (array[j] <= pivot) 

{

// If element found is smaller than pivot

//it will be swapped with the larger element pointed by i

i++;

// element at i is swapped with element at j

int s = array[i];

array[i] = array[j];

array[j] = s;

}

}

// swapt the pivot element with the greater element specified by i

int s = array[i + 1];

array[i + 1] = array[rightmost];

array[rightmost] = s;

// return the position from where partition is done

return (i + 1);

}

static void quickSort(int array[], int leftmost, int rightmost) 

{

if (leftmost < rightmost) 

{

int pi = partition(array, leftmost, rightmost);

// recursive call on the left of pivot

quickSort(array, leftmost, pi - 1);

// recursive call on the right of pivot

quickSort(array, pi + 1, rightmost);

}

}

}

class Main 

{

public static void main(String args[]) 

{

int[] arr = { 5, 4, 6, 1, 0, 8, 3 };

System.out.println("Unsorted Array");

System.out.println(Arrays.toString(arr));

int size = arr.length;

Quicksort.quickSort(arr, 0, size - 1);

System.out.println("Sorted Array in Ascending Order: ");

System.out.println(Arrays.toString(arr));

}

}

```

#Output:

```sh

Unsorted Array

[5, 4, 6, 1, 0, 8, 3]

Sorted Array in Ascending Order: 

[0, 1, 3, 4, 5, 6, 8]

```

Dropdown Icon

#Coding Question2 

Write a program to count the number of vowels occurring in all the substrings of a given String.

#Solution:

```sh

import java.io.*;

import java.util.*;

import java.util.Scanner; 

public class Main {

//calculates total sum of all vowel occurrences

static int vowel_calc(String str)

{

int n = str.length();

int arr[] = new int[n];

for (int i = 0; i < n; i++) 

if (i == 0)

// Number of times the 0th character occurs in all substrings

arr[i] = n; 

else

// Number of times the ith character occurs in all substrings

arr[i] = (n - i) + arr[i - 1] - i;

}

int sum = 0;

for (int i = 0; i < n; i++) {

char ch = str.charAt(i);

// Check to see if ith character is a vowel

if (ch == 'a' || ch == 'e' || ch == 'i' || ch == 'o' || ch == 'u')

sum += arr[i];

}

// Return total sum of all vowel occurrences      

return sum;

}

// Driver Code

public static void main(String args[])

{

Scanner sc= new Scanner(System.in); 

System.out.println("Enter a String");

String str=sc.nextLine();

System.out.println(vowel_calc(str));

}

}

```

#Output:

```sh

Enter a String

Scaler

22

```

Dropdown Icon

#Coding Question4

Write a Java Program to Display Alternate Prime Numbers


#Solution

```sh

import java.util.Scanner;

class AlternatePrimeNumbers {

public static void main(String[] args) {

Scanner input = new Scanner(System.in);

System.out.print("Enter the range: ");

int range = input.nextInt();

input.close();

boolean isPrime;

int counter = 0;

System.out.println("Alternate Prime Numbers: ");

for (int num = 2; num <= range; num++) {

isPrime = true;

for (int i = 2; i <= num / 2; i++) {

if (num % i == 0) {

isPrime = false;

break;

}

}

if (isPrime) {

counter++;

if (counter % 2 == 0) {

System.out.print(num + " ");

}

}

}

}

}

```

Dropdown Icon

#Coding Question3

Print ASCII Value in Java

#Solution:

```sh

public class PrintAsciiValueExample1   

{  

public static void main(String[] args)   

{  

// character whose ASCII value to be found  

char ch1 = 'a';  

char ch2 = 'b';  

// variable that stores the integer value of the character  

int asciivalue1 = ch1;  

int asciivalue2 = ch2;  

System.out.println("The ASCII value of " + ch1 + " is: " + asciivalue1);  

System.out.println("The ASCII value of " + ch2 + " is: " + asciivalue2);  

}  

}  

```

#Output:

```sh

The ASCII value of a is: 97

The ASCII value of b is: 98

```

Dropdown Icon

#Coding Question5

Write a Java Program to find Third Largest Number in an Array


#Solution

```sh

public class ThirdLargestInArrayExample{  

public static int getThirdLargest(int[] a, int total){  

int temp;  

for (int i = 0; i < total; i++)   

{  

for (int j = i + 1; j < total; j++)   

{  

if (a[i] > a[j])   

{  

temp = a[i];  

a[i] = a[j];  

a[j] = temp;  

}  

}  

}  

return a[total-3];  

}  

public static void main(String args[]){  

int a[]={1,2,5,6,3,2};  

int b[]={44,66,99,77,33,22,55};  

System.out.println("Third Largest: "+getThirdLargest(a,6));  

System.out.println("Third Largest: "+getThirdLargest(b,7));  

}}  

```

#Output:

```sh

Third Largest:3

Third Largest:66

```

Dropdown Icon
Dropdown Icon
Dropdown Icon
Dropdown Icon

#Popular Question1

#Game of Profit

You’re given the predicate price of XYZ company’s share for every minute. Each minute, you’re allowed to either buy one share of XYZ or sell any number of shares of XYZ that you own or not make any transaction at all. Your task is to find out the max profit.

#Constraints:

```sh

1 <= T <= 10

1 <= N <= 5*10^5

All share price are between 1 and 10^5

```

#Sample Input:

```sh

3

3

5 3 2

3

1 2 100

4

1 3 1 2

```

#Output:

```sh

0

197

3

```

Dropdown Icon

#Popular Question2

#Student for Viva

The seasons of the vivas are ON!! There are a number of students in a class. Each class of students has to give viva, but there is one rule teacher has decided to choose the student whose turn it will give viva. The teacher is picking a certain role number from the list of the students. On each day, students with a high role number than his left student role number will be picked to give viva on that day. Determine the number of days after which no student from the initial picking is remaining to give viva, i.e the time after which there is no student with a higher roll number on his left.

#Example:

roll_numbers = [3, 6, 7, 5] (roll numbers of the students randomly picked initially amongst all students)

Use a 1-indexed array. On day 1, roll numbers 6 and 7 will be picked to give viva leaving roll_numbers = [3, 2, 5]. On day 2, roll numbers 5 will be picked for viva leaving roll_numbers = [3, 2]. There is no student with a higher roll number than one to its left, so that batch will be over with the viva and will be ready to enjoy the vacations.

#Constraints:

```sh

1 <= n <- 10^5

1 <= roll_number[i] <= 10^9

```

#Sample Input:

```sh

7

6 5 8 4 7 10 9

```

#Output:

```sh

2

```

Dropdown Icon

#Popular Question3

#Oxygen Cylinders Management

You’ve given a list of covid patients where patient[i] is the required by the ith patient, and there are enough cylinders where each cylinder contains a limited amount of oxygen. Each cylinder can serve at most two patients at the same time, provided the array of the oxygen required by the patients and cylinder capacity. Return the minimum quantity of cylinders to serve all patients.

#Constraints:

```sh

1 <= n <=10000

1 <= patients[i] <= limit <=3 * 10000

```

#Sample Input:

```sh

2

1

1

2

```

#Sample Output:

```sh

1

```

Dropdown Icon
Dropdown Icon
Dropdown Icon
Dropdown Icon
Dropdown Icon
Dropdown Icon
Dropdown Icon

Technical Interview Round Sample Questions 

Here are some examples of technical interview questions that may be asked (entry-level candidates with little or no professional experience):
Can java be said to be the complete object-oriented programming language?
Dropdown Icon
Coding Question
Dropdown Icon
Coding Question
Dropdown Icon
Coding Question
Dropdown Icon
Coding Question
Dropdown Icon
Coding Question
Dropdown Icon
How can you assure that you are the eligible person for EPAM?
Dropdown Icon
How is Java different from C++?
Dropdown Icon
Pointers are used in C/ C++. Why does Java not make use of pointers?
Dropdown Icon
Popular Question
Dropdown Icon
Popular Question
Dropdown Icon
Popular Question
Dropdown Icon
What are your hobbies?
Dropdown Icon
What does EPAM stand for?
Dropdown Icon
What happens when a method or variable contains the static keyword?
Dropdown Icon
What is the difference between the program and the process?
Dropdown Icon
What was your childhood dream to be in the future?
Dropdown Icon
Why have you chosen EPAM?
Dropdown Icon

HR Interview Round Sample Questions

Here are some examples of technical interview questions that may be asked (entry-level candidates with little or no professional experience):
Can java be said to be the complete object-oriented programming language?
Dropdown Icon
Coding Question
Dropdown Icon
Coding Question
Dropdown Icon
Coding Question
Dropdown Icon
Coding Question
Dropdown Icon
Coding Question
Dropdown Icon
How can you assure that you are the eligible person for EPAM?
Dropdown Icon
How is Java different from C++?
Dropdown Icon
Pointers are used in C/ C++. Why does Java not make use of pointers?
Dropdown Icon
Popular Question
Dropdown Icon
Popular Question
Dropdown Icon
Popular Question
Dropdown Icon
What are your hobbies?
Dropdown Icon
What does EPAM stand for?
Dropdown Icon
What happens when a method or variable contains the static keyword?
Dropdown Icon
What is the difference between the program and the process?
Dropdown Icon
What was your childhood dream to be in the future?
Dropdown Icon
Why have you chosen EPAM?
Dropdown Icon