Tip 1: Go through the Amazon DSA questions on coding platforms.
Tip 2: Learn in depth about Linux commands and Shell scripting.
Tip 3: Prepare for behavioural questions based on the Leadership Principles.
Tip 1: Match the job description in your resume.
Tip 2: Be clear and concise.
The first round will be an online assessment with some business scenario questions (level: easy) and multiple-choice questions on Linux and scripting.
A written test on coding (two easy DSA questions), Linux commands, troubleshooting, and shell scripting.



If the given string is: STR = "abcde". You have to print the string "edcba".
Try to solve the problem in O(1) space complexity.
- I need to take a sample string and proceed with coding.
- I used a swapping approach with two pointers: one at the start and one at the end of the string.
- Once the start pointer is equal to or greater than the end pointer, return from the code.



- I created an empty array (vector) to store the unique elements.
- I used two loops to traverse through the array.
- I added only the unique elements to the newly created array and returned the result.
Two DSA questions were asked — one easy and one medium.

- In any condition, the rightmost element will be visible and hence will be added to the output array.
- I traverse from the end of the array to the first element and compare each with the largest element stored in the output array.
- If the number found in the array is larger than the element stored in the output array, it is then added to the output array.



- It can be solved using the two-pointer approach (i, j).
- If the first element is 1, the j pointer is moved forward until it finds the value 0.
- If a 0 is found, it is swapped with the i pointer, which is still at the value 1.
The second face-to-face interview focused on Shell scripting, Linux commands, and my previous project experience.
Write a shell script to find all words starting with "process" in a file at a Unix path, print those lines, and save them to an output file.
- I used the grep command to search for the word.
- The | (pipe) command can be used to send the output of the first command as input to the next command.
- Save the result in a new file.
Write a shell script to find all 10-digit mobile numbers in a file.
- Use the awk command for pattern searching.
- sed is another command that can be used.
Explain a few Linux commands that you know.
This round was conducted by the Hiring Manager. I was asked one Java DSA question and behavioural questions about my previous project experiences. This round primarily focused on evaluating my alignment with the Leadership Principles.



I traversed through the loop, and the output string was added to another string.
This round was called the Bar Raiser.
All the questions were behavioural, designed to test Amazon's Leadership Principles.
This round was called the Bar Raiser. Questions were based on Amazon's Leadership Principles.

Here's your problem of the day
Solving this problem will increase your chance to get selected in this company
How do you remove whitespace from the start of a string?