Zscaler Softech
ITI Asset Management Interview Questions and Answers
Q1. How to create singleton ensuring reflection does not mess up the implementation
To create a singleton ensuring reflection does not mess up the implementation, use an enum or a private constructor with a static field.
Use an enum to create a singleton as enums are inherently singletons and cannot be instantiated multiple times.
Alternatively, use a private constructor with a static field to create a singleton.
To prevent reflection from creating multiple instances, throw an exception in the constructor if an instance already exists.
Q2. Swap character from uppercase to lowercase and lowercase to uppercase Zscalar ->zSCALAR without using 1.util function 2.arithimatic operator 3.map 4.array function
Swap characters from uppercase to lowercase and lowercase to uppercase in a given string.
Iterate through each character in the string
Check if the character is uppercase or lowercase
Swap the case of the character using bitwise XOR operation
Build the resulting string with the swapped characters
Q3. How to handle millions of request from clients?
Use load balancing, caching, and scaling techniques to handle millions of requests from clients.
Implement load balancing to distribute requests evenly across servers.
Utilize caching mechanisms to store frequently accessed data and reduce load on servers.
Scale horizontally by adding more servers to handle increased traffic.
Optimize code and database queries to improve performance and reduce response times.
Q4. Difference. Between concurrent hash map and synchronised hashmap
ConcurrentHashMap allows multiple threads to access and modify the map concurrently, while SynchronizedHashMap ensures thread-safety by allowing only one thread to access the map at a time.
ConcurrentHashMap is more efficient in scenarios with high concurrency as it allows concurrent read and write operations.
SynchronizedHashMap is simpler to use and provides thread-safety, but can lead to performance degradation in highly concurrent environments.
ConcurrentHashMap achieves thr...read more
Q5. Semaphores in java how to implement
Semaphores in Java are used for controlling access to a shared resource. They can be implemented using the java.util.concurrent package.
Use the Semaphore class from the java.util.concurrent package
Create a Semaphore object with an initial number of permits
Use the acquire() method to acquire a permit before accessing the shared resource
Use the release() method to release a permit after accessing the shared resource
Q6. Bitmask in Postgresql how to use
Bitmask in Postgresql is used to store and manipulate multiple boolean values within a single integer column.
Bitmask is a technique to represent a set of boolean flags using binary digits.
In Postgresql, the bitwise operators (&, |, ^, ~) can be used to perform operations on bitmasks.
To set a specific flag in a bitmask, use the bitwise OR operator (|).
To check if a flag is set in a bitmask, use the bitwise AND operator (&).
To toggle a flag in a bitmask, use the bitwise XOR ope...read more
Q7. Best time to buy and sell stock
The best time to buy and sell stock is when the price is low to buy and high to sell, maximizing profit.
Buy when the stock price is low and sell when it is high
Consider market trends and analysis to predict the best time to buy and sell
Avoid emotional decision-making and stick to a well-thought-out strategy
Q8. Implement a circular list.
Implement a circular list
Use a linked list where the last node points back to the first node
Keep track of the current node for easy traversal
Ensure proper handling of edge cases like empty list or single node
Q9. Create a bar graph
Creating a bar graph using array of strings
Create an array of strings representing the data points for the bar graph
Each string should indicate the value of the bar and its corresponding label
Use a visualization tool or library to plot the bar graph based on the array of strings
Interview Process at ITI Asset Management
Top Senior Software Engineer Interview Questions from Similar Companies
Reviews
Interviews
Salaries
Users/Month