Programming Fundamentals and Code Quality Questions
Encompasses core programming skills, data structures, basic algorithms, language fundamentals, and code quality practices. Expect proficiency with arrays, strings, lists, hash maps or dictionaries, sets, common collection operations, basic sorting and searching algorithms, and tradeoffs between data structures. Understand control flow, functions and modular design, classes and object oriented programming concepts including encapsulation, inheritance, and polymorphism, exception handling, file input and output, and common language idioms for mainstream interview languages such as Python, Java, and C plus plus. Emphasizes writing clean, readable, maintainable code: meaningful naming, modular functions, small interfaces, handling edge cases and errors, logging and documentation, simple testing and debugging strategies, and awareness of time and space complexity for common operations. Candidates should be able to implement correct solutions, follow language specific idioms where appropriate, and demonstrate attention to code quality and readability.
MediumTechnical
0 practiced
Explain race conditions and deadlocks with concrete code examples using Java synchronized blocks. Describe strategies to avoid deadlocks such as consistent lock ordering, timeouts, deadlock detection, and alternatives like lock-free data structures.
MediumSystem Design
0 practiced
Design and implement a Python generator `data_loader(shards, batch_size, seed, shuffle=True)` that yields minibatches from multiple shard files on disk. Requirements: deterministic shuffling given seed across epochs, minimal memory footprint, support for variable-size shards, and reproducible behavior across process restarts. Provide concise sample code and explain choices.
MediumTechnical
0 practiced
Implement a Java function `binarySearchTimestamps(long[] arr, long target)` that returns the index of the largest timestamp <= target in a sorted ascending array, or -1 if all timestamps are greater than target. Handle edge cases carefully and discuss complexity and numerical pitfalls.
EasyTechnical
0 practiced
Describe the differences between list and tuple in Python and when you would choose one over the other in ML/AI projects. Discuss mutability, hashability, performance implications, and give example cases where tuples prevent accidental mutation in data pipelines. Include small code examples showing conversion and practical cases.
MediumTechnical
0 practiced
Implement a thread-safe counter class in modern C++ that supports atomic increment and read operations with minimal overhead. Provide both an atomic-based implementation and a mutex-based implementation and explain tradeoffs between them, especially under high contention.
Unlock Full Question Bank
Get access to hundreds of Programming Fundamentals and Code Quality interview questions and detailed answers.