InterviewStack.io LogoInterviewStack.io

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
28 practiced
You have a 100GB log file where each line is a JSON event and available memory is 200MB. Describe an algorithm to output a deduplicated stream of events by event_id, preserving the first occurrence order as much as possible. Provide a high-level implementation approach in Python or pseudocode and explain trade-offs between accuracy, memory, and processing time.
MediumTechnical
28 practiced
Design and implement a cache in Python that supports get/put, per-key TTLs, and LRU eviction when capacity is exceeded. Ensure expired keys do not count toward capacity. Describe complexity and how you handle clock skew and concurrent access if used by multiple threads.
MediumTechnical
26 practiced
How do you choose linters and static analyzers for a mixed codebase with Python, Go, and Bash scripts? Discuss which classes of issues to catch with tooling (style, correctness, security), how to tune rules to balance noise vs value, and strategies for onboarding the team to new checks without slowing development.
MediumTechnical
24 practiced
Implement a thread-unsafe LRUCache class in Python supporting get(key) and put(key, value) with O(1) operations and a fixed capacity. Provide the implementation, explain time and space complexity, and discuss how you would make it thread-safe for use in a monitoring agent.
MediumTechnical
33 practiced
Explain the differences between multi-threading, multi-processing, and asyncio in Python including use-cases, limitations (including the GIL), trade-offs for IO-bound vs CPU-bound tasks, debugging implications, and how each model affects SRE tooling design.

Unlock Full Question Bank

Get access to hundreds of Programming Fundamentals and Code Quality interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.