Taro Logo

SDE 1 Interview Experience - Bengaluru, India

August 1, 2022
Positive ExperienceGot Offer

Process

Brillio Interview — Technical Round

The interview started with a brief self-introduction. I was asked to explain my current role, technical experience, projects I had worked on, and the technologies I had used.

After the introduction, the interviewer moved directly into DSA/coding questions in Java. The questions were relatively straightforward and focused more on problem-solving approach, understanding of Java syntax, and ability to write clean and correct code.

Check if a String is a Palindrome

Question: Given a string, determine whether it is a palindrome.

A palindrome is a string that reads the same forward and backward.

Examples:

Input: "madam" Output: true

Input: "hello" Output: false

Input: "racecar" Output: true

Expected approach: I would explain the two-pointer approach:

  • Keep one pointer at the beginning of the string.

  • Keep another pointer at the end.

  • Compare the characters.

  • If they are different, the string is not a palindrome.

  • Move the pointers toward the center.

  • If all characters match, the string is a palindrome. public static boolean isPalindrome(String str) { int left = 0; int right = str.length() - 1;

    while (left < right) { if (str.charAt(left) != str.charAt(right)) { return false; }

      left++;
      right--;
    

    }

    return true; }

Complexity:

Time: O(n) Space: O(1)

The interviewer may also ask follow-up questions such as:

Can you solve it without creating another string? What is the space complexity? What happens for an empty string? What about strings containing spaces or special characters? Can you solve it using recursion? Reverse a String

Question: Given a string, reverse it.

Examples:

Input: "hello" Output: "olleh"

Input: "Brillio" Output: "oillirB"

Approach 1 — Two pointers / character array

Since Java Strings are immutable, one clean approach is to convert the string into a character array and swap characters from both ends.

public static String reverse(String str) { char[] chars = str.toCharArray();

int left = 0;
int right = chars.length - 1;

while (left < right) {
    char temp = chars[left];
    chars[left] = chars[right];
    chars[right] = temp;

    left++;
    right--;
}

return new String(chars);

}

Complexity:

Time: O(n) Space: O(n)

The O(n) space comes from the character array.

Was this helpful?

Interview Statistics

The following metrics were computed from 1 interview experience for the Brillio SDE 1 role in Bengaluru, India.

Success Rate

100%
Pass Rate

Brillio's interview process for their SDE 1 roles in Bengaluru, India is incredibly easy as the vast majority of engineers get an offer after going through it.

Experience Rating

Positive100%
Neutral0%
Negative0%

Candidates reported having very good feelings for Brillio's SDE 1 interview process in Bengaluru, India.