College - Tier 3
Current Org - SAP Labs
YoE - 1.7
Tech - FullStack Web Dev Angular + Java SpringBoot
Visa Inc SDE-1 Interview experience (round 4) [3 round already appeared]
Round 1 - DSA, Round 2 - General Resume & System Design concepts, Round 3 - HM
Round 4 for another team, team fit + java springboot & work related
Questions -
- What java version version do you use
Ans - 17
- New features introduced in java 17
Ans - told java 8 & 11 features streams, optionals, lambda etc
- List of Emp POJO with name, id etc. filter it via streams where name starts with your first name
- Sort the same list via streams in reversed
Ans - told interviewer there is a .sorted method but I dont remember the syntax, interviewer was fine doing it with list.sort + comparator lambda, asked follow up about comparator & lambda
- Tell me about the different map versions you know in java
Ans - hashmap, treemap, (was about to add LHMap & ConcHMap but cut off)
- How does a hashmap works internally
Ans - .equals and .hashCode, explained it well with collision and buckets
hash collision (chaining, open addressing, double hashing)
again asked about chaining
mentioned a LL may be used
follow up question was TC of chaining insert
O(m), where m is number of collisions
then asked how you would improve this TC
better hashing should be the focus, also said something like a list and maybe using some hash function to get the index and retrieve (wrong answer was anxious)
interviewer gave hint about ordering & trees
discussed about sorted list and binary search. still couldnt get it, AVL trees as values was the answer (didn't know)
- what version of springboot do you use
Ans - 3.3
- what is dependency injection in springboot and advantages
Ans - discussed about Beans, IOC, DI, @Autowired
benefits of DI
loose coupling, easy testing & mocking, cyclicity managed by sboot and singleton hence less space
follow up about what is singleton
- if a prototype bean is autowired inside inside singleton bean, would it act like prototype?
Ans - no, prototype wouldnt be created each time
- what types of databases have you used?
Ans - postgreSQL, mongoDB & hanaDB
follow up inquired about hana is it SQL or no-SQL
- given a table with id and gender, find the count of male and females via SQL query
Ans - SELECT gender, count(id) FROM emp GROUP BY gender;
had the right intuition in beginning to use group by gender & count id mentioned that but got confused when writing query. said can do it in 2 distinct query
- Given list of words find the longest common prefix among them
Ans- iterating and comparing starting m chars among all words O(mn) and trie solution
- flipped the question to find longest common substring among words
- tell me about a time you had faced a challenge and what did you learn from it
Ans - work related discussion & follow up questions
- this job can be very monotonous how do you deal with it
Ans - used the STAR method to discuss about current work monotonous & how I deal with it
- how do you stay uptodate and relevant with what's happening in the field
- what do you think about genAI
Verdict - Selected
Comp - Base 17LPA, Annual pay 20.1LPA
Stocks 18,000 USD over 3 years