Design: simple chat app
- first start it with just 2 users
- what server, websocket or any other server
- EC2, what's the usage
- How would you establish the connection to the server if there are multiple users.
- Authentication
- Where DNS is located? within the server?
Network:
- TCP ? when to use TCP/UDP
- what happens when you something on google
- First the request will go to DNS or server?
DSA:
https://leetcode.com/discuss/post/5904685/salesforce-oa-6-oct-by-anonymous_user-hipt/
LLD - Singleton:
- Write a singleton class which works in a multithreaded env
- Will synchrhonized keyword fix the problem?
- Synchronized is mutex or semaphore?
Multithreading:
Create 2 threads, 1st will print odd numbers and 2nd will print even numbers.
you should not have a global counter
once the first thread is called 1 should be printed
until the 2nd thread is called it should wait
2nd thread is called and it should print 2
then if 1st thread should print 3 and so
How will you synchronize it?
Distributed systems:
CAP theorem
Fault tolerence
DB replica - will be in same node or different
2 hours of interview - just waste of time.
Comments (2)


