Restolabs

restolabs logo
restolabs
· Full stack developer· Ongoing
September 24, 2022 · 175 reads

Summary

I interviewed for a Full stack developer position at Restolabs, covering four core technical problems including Fibonacci series, palindrome generation, finding a celebrity in a party, and determining the year with maximum population. I am currently awaiting the final verdict.

Full Experience

My Interview Experience at Restolabs

I recently had an interview for a Full stack developer role at Restolabs. The interview focused heavily on data structures and algorithms, with four distinct problems presented.

For the first question, I was asked to find the first number in the Fibonacci series that has n digits, which I approached using a prefix sum technique. The second problem involved printing all possible palindromes from a given string, where I attempted a brute force solution.

The third question was a classic "Find the Celebrity" problem, requiring me to identify a unique person in a party who is known by everyone else but knows no one. I tried to apply a SSSP (Single Source Shortest Path) logic using BFS for this.

Finally, I was presented with a problem about population analysis: given people's birth and death years, find the year with the maximum population in the city. The verdict for my interview is currently pending.

Interview Questions (4)

1.

Nth Fibonacci Number with N Digits

Data Structures & Algorithms

Given a number n, find the first number in the Fibonacci series that has n digits.

2.

Print All Palindromes in a String

Data Structures & Algorithms

Print all possible palindromes in a given string.

3.

Find the Celebrity

Data Structures & Algorithms

In a party, there are many people and a celebrity. All people know the celebrity, and can know other people, but the celebrity knows no one in the party. Find the minimum number of ways to find the celebrity. For this, we can ask questions to people, for example: 'Do you know B?'. For instance, if A knows B, B knows C, and C does not know D, then C is the celebrity.

4.

Year with Maximum Population

Data Structures & Algorithms

Given many people with their birth and death years (e.g., birth 2000 and death 2060), find the year in which the city has the maximum population.

📣 Found this helpful? Please share it with friends who are preparing for interviews!

Discussion (0)

Share your thoughts and ask questions

Join the Discussion

Sign in with Google to share your thoughts and ask questions

No comments yet

Be the first to share your thoughts and start the discussion!