PracHub
QuestionsPremiumLearningGuidesCheatsheetNEWCoaches
|Home/Software Engineering Fundamentals/Apple

Explain Runnable vs Callable and thread-safe Singleton

Last updated: Mar 29, 2026

Quick Overview

This question evaluates a candidate's knowledge of Java concurrency and design patterns, specifically distinctions between Runnable and Callable, mechanisms for result retrieval and exception handling, and the principles underlying thread-safe Singleton implementations.

  • medium
  • Apple
  • Software Engineering Fundamentals
  • Software Engineer

Explain Runnable vs Callable and thread-safe Singleton

Company: Apple

Role: Software Engineer

Category: Software Engineering Fundamentals

Difficulty: medium

Interview Round: Technical Screen

## Concurrency & Design Patterns (Java) 1. In Java concurrency, what is the difference between `Runnable` and `Callable`? - When would you choose one over the other? - How do you retrieve results and handle exceptions for each? 2. Name one or two design patterns you have used in real projects. 3. For the Singleton pattern, explain what it means for a Singleton to be **thread-safe**. - Why can a naïve lazy Singleton be unsafe under concurrency? - Describe at least one correct way to implement a thread-safe Singleton in Java and why it works.

Quick Answer: This question evaluates a candidate's knowledge of Java concurrency and design patterns, specifically distinctions between Runnable and Callable, mechanisms for result retrieval and exception handling, and the principles underlying thread-safe Singleton implementations.

Related Interview Questions

  • How to debug a Python loop-condition bug - Apple (medium)
  • How to root-cause Wi‑Fi chip stops after 30 minutes - Apple (medium)
  • Design a deck of cards with shuffle/draw - Apple (medium)
  • Explain thermal and signal fundamentals - Apple (hard)
  • Explain key React concepts and error handling - Apple (medium)
Apple logo
Apple
Jan 17, 2026, 12:00 AM
Software Engineer
Technical Screen
Software Engineering Fundamentals
6
0
Loading...

Concurrency & Design Patterns (Java)

  1. In Java concurrency, what is the difference between Runnable and Callable ?
    • When would you choose one over the other?
    • How do you retrieve results and handle exceptions for each?
  2. Name one or two design patterns you have used in real projects.
  3. For the Singleton pattern, explain what it means for a Singleton to be thread-safe .
    • Why can a naïve lazy Singleton be unsafe under concurrency?
    • Describe at least one correct way to implement a thread-safe Singleton in Java and why it works.

Solution

Show

Comments (0)

Sign in to leave a comment

Loading comments...

Browse More Questions

More Software Engineering Fundamentals•More Apple•More Software Engineer•Apple Software Engineer•Apple Software Engineering Fundamentals•Software Engineer Software Engineering Fundamentals
PracHub

Master your tech interviews with 7,500+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • For Universities
  • Student Access

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.