© Interview RuntimeThis content is copyright. Copying is disabled; you may quote a short excerpt with a link to the page.

Senior iOS interview practice for answering out loud, taking the follow-up and retrying

7 senior iOS prompts turned into a practice loop. Answer aloud, take the follow-up, score the evidence and come back to the same question.

Engraving of a tuning fork struck and resting on a wooden resonator box.

In short

  • Answer each prompt aloud before reading the discussion, and mark the moment you became uncertain.
  • A guarantee is only half an answer until you state its cost and the condition under which you would choose differently.
  • Actor isolation prevents unsynchronised access. It does not make an asynchronous method indivisible.
  • Stable SwiftUI identity preserves state. It does not decide whether that state should survive navigation.
  • Retry each prompt after a changed constraint, not after rereading the answer.

“It's a struct, so it's copied.”

Copied how? What happens to the reference stored inside it? What changes when you mutate an array that shares storage with another value?

A short Swift answer can be accurate and still leave the important decision unexplained. Senior iOS interview questions become useful practice when you rehearse the consequences of an answer, including the condition under which you would choose something else.

This article turns 7 senior iOS prompts into a practice loop. They cover value semantics, memory, actors, SwiftUI, architecture, testing and performance. They are original training questions selected for coverage, not a ranked list measured across employers.

Attempt each answer aloud before reading the discussion. The suggested answers are examples of defensible reasoning, not scripts to memorise or universal hiring criteria.

The practice loop

Use the same loop for every prompt.

  1. Pick 1 prompt. Read only the question, and set a 2-minute timer.
  2. Answer aloud without notes. Record your screen and voice if you can. When you become uncertain, mark that moment.
  3. Take the follow-up. Read it only after your first answer is finished.
  4. Score the attempt. Compare it with the discussion and label it demonstrated, demonstrated after a prompt, needs repair or not reached. Attach the sentence, sketch or test that supports the label.
  5. Retry after a changed detail. Come back to the same prompt a day later, add the condition from the follow-up, and answer again without reading.

For the full list of questions, see the senior iOS developer interview questions and answers.

Keep a sheet like this for every attempt.

PromptWhere I became uncertainEvidence I would checkScoreRetry date
Name of the promptThe sentence I could not supportThe test, sketch or source that settles it1 of the 4 labelsDate and changed detail

1. Does choosing a struct guarantee independent state?

Question. You copy a model struct that contains a reference to a mutable object. Can changing that object affect both copies?

What it checks. Whether you separate value semantics for the outer container from the state of the objects it references.

An answer that stops too early. “Structs are value types, so each copy is independent.”

A reasoned answer. Copying the struct copies its stored property values. A stored class reference can still point to the same object from both copies. Value semantics for the outer container do not recursively turn referenced mutable objects into independent values.[1]

If independence is a requirement, decide whether the referenced object should be immutable, explicitly copied or replaced with a value representation. Explain the cost of that choice. A deep copy may allocate and traverse a graph; sharing may require ownership or synchronisation rules.

Follow-up. An array is copied and then mutated. Must both the assignment and mutation copy every element?

Assignment copies no elements. The first mutation copies the storage only if another value still shares it. Separate semantic independence from physical storage strategy. Swift's standard collections use copy-on-write optimisations. Do not infer allocation or mutation cost from the word “struct” alone. State what operation you would measure if the cost matters.

Practise it. Draw the 2 structs and the object they reference. Then replace the class property with an immutable value and explain what changed.

If you want this loop scored against a rubric and repeated after a changed constraint, iOS Interview Training is built for that routine.

2. Will adding weak self fix a screen that never deallocates?

Question. A screen model retains a task handle. The task reads an asynchronous stream and refers to the model. The model's deinitializer never runs.

What it checks. Whether you can trace the retention graph and end the work with the owner that defines its lifetime.

An answer that stops too early. “Use weak self in every closure.”

A reasoned answer. Identify the retention graph and the intended lifetime of the work. A task that obtains a strong reference to the model and keeps it across an indefinitely running operation can prevent deallocation. Cancelling only from that model's deinitializer may be too late to establish the lifetime you intended.

Choose an owner that can end the work when the screen no longer needs it. Review what the task captures and how long a strong reference is retained after a weak capture is unwrapped. ARC's weak and unowned references address reference ownership; they do not, by themselves, define task cancellation.[2]

Follow-up. Should the work continue after navigation?

If it is a screen subscription, end it with the relevant owner. If it is a durable upload, move responsibility to a component designed for that requirement. “The screen disappeared” is not automatically the correct lifetime for every operation.

Practise it. Name the event that ends the work, the object that receives that event and the behaviour of the underlying operation on cancellation.

3. Can an actor still allow duplicate requests?

Question. An actor checks its cache, awaits a download and stores the result. Several callers ask for the same missing URL. What can happen?

What it checks. Whether you know that isolation does not hold across an await, and whether you can design work that callers share.

An answer that stops too early. “The actor serialises calls, so it downloads once.”

A reasoned answer. While a method is suspended, another call can inspect the same missing entry. Isolation prevents concurrent unsynchronised access to actor state; it does not make the whole asynchronous method an indivisible operation. The same effect is called actor reentrancy.[3][6]

Store a representation of in-flight work before suspension if callers should share it. Define what happens when the work fails, when 1 waiter cancels and when an entry is invalidated. A flag alone does not provide the other callers with a result to await.

Follow-up. A caller from an old flight resumes after a replacement flight has started. Can its cleanup remove the replacement?

Associate cleanup with the operation's identity. Removing whatever happens to be stored under the URL can erase newer work.

Practise it. Order the events on paper. For an implementation exercise, write the same cache in a small Swift project and test it with 2 concurrent callers. The concurrency questions cover the language model in more detail.

4. Why does SwiftUI state disappear after a refresh?

Question. Editable rows lose local state after their data refreshes. Where would you start?

What it checks. Whether you can tell a recreated view identity from changed data, and whether the state's lifetime matches the requirement.

An answer that stops too early. “SwiftUI redraws the screen. Put everything in a view model.”

A reasoned answer. Inspect identity and ownership. A row whose identifier changes on every fetch may be treated as a different conceptual row. Structural changes or an explicit identity modifier can also change the lifetime of state. Apple's SwiftUI explanation ties persistent state to view identity.[4]

Once identity is correct, ask whether row-local lifetime matches the requirement. A draft expected to survive navigation may need a longer-lived owner or persistence. The same fix does not follow from every state-reset symptom.

Follow-up. A stable ID retains a draft for a product whose server value changed. Which value should the user see?

Now the problem is reconciliation. Define whether the draft remains authoritative until submission, whether the user sees a conflict or whether the server update replaces it. Stable identity preserves continuity; it does not select a conflict policy.

Practise it. Separate “the row was recreated” from “the data changed” and “the product requires a longer draft lifetime”.

5. How would you modularise an existing iOS app?

Question. Several teams work in a single app target. Build times and merge conflicts are painful. What is the first module you extract?

What it checks. Whether you can scope a boundary from a measured problem rather than from an architecture label.

An answer that stops too early. “Create feature, domain and data modules for every screen.”

A reasoned answer. First establish the concrete problem and dependency graph. Find a boundary with clear ownership, a small public contract and a migration that can be delivered without blocking the whole product. Measure whether the extraction addresses the stated problem.

For a build-time complaint, distinguish clean builds, incremental builds and the particular edits developers make frequently. A new module may reduce some rebuilds while adding dependency or configuration overhead. For merge conflicts, the main issue may be shared ownership or generated files rather than target count.

Follow-up. The proposed module needs private types from 3 features.

That is evidence to revisit the boundary. Consider changing the contract, moving shared policy to an explicit owner or choosing a smaller first extraction. Do not export the entire implementation just to get a dependency diagram that looks clean.

Practise it. Propose 1 extraction, 1 risk, 1 migration step and 1 measure of whether it helped.

6. How do you test an asynchronous race reliably?

Question. A test passes locally but fails when a slower response reaches the model after a newer one.

What it checks. Whether you can control the order of events in a test instead of hoping that timing produces it.

An answer that stops too early. “Increase the timeout and add a sleep.”

A reasoned answer. Make the relevant order controllable. Inject the service, observe when requests start and complete them manually in the order that challenges the invariant. Assert the final state after each important completion.

Timeouts can bound a test that would otherwise hang. They should not be the mechanism that makes an event happen before another event. Keep transport integration tests separate from the model's state-transition tests.

Follow-up. The cancelled request still returns a value from the fake.

That is a useful adversarial case if the publication boundary should reject cancelled or obsolete results. Label the fake's behaviour and verify the invariant. It does not prove that every real networking layer behaves identically.

Practise it. Test obsolete success and obsolete failure separately. They often travel through different code paths, including cleanup.

7. How would you investigate a scrolling regression?

Question. A feed scrolls poorly on some devices after a release. What do you change first?

What it checks. Whether you measure before you change code, and whether you can read an average against the slowest interactions.

An answer that stops too early. “Use a lazy container and move work off the main thread.”

A reasoned answer. Reproduce the affected user journey on representative hardware, identify the relevant release and capture a trace. Separate expensive layout, image preparation, database work, main-thread blocking and memory pressure before choosing a change. Apple's hang-analysis material demonstrates investigation through recording and analysis.[5]

Establish a baseline with the same content, cache state and build conditions. A simulator observation or a debug-only experiment may help diagnosis but should not become an unqualified production performance claim.

Follow-up. The change improves average timing but worsens the slowest interactions.

Inspect the distribution and the user impact. Explain why an average alone cannot establish that the regression is repaired. Define which outcome matters for the feature and keep the comparison conditions stable.

Practise it. Write the first hypothesis, the trace that could reject it and the measurement you would compare after the fix.

Use the questions as a diagnostic

For each prompt, keep the first recording, the point where the explanation became uncertain and the example that would verify it. Mark unattempted topics as untested rather than assuming familiarity means readiness.

Repair 1 gap, then answer a changed version. If your revision only improves the wording, test whether the underlying model also improved.

For a timed session, run a 60-minute practice round with a colleague or alone. It combines clarification, a controlled test and a follow-up in a single sitting, which shows more than a list of answers can.

Continue with structured practice

iOS Interview Training is $99, paid once. You keep the book and companion code, and you get 90 days of Guided Practice. You answer realistic prompts, inspect weaknesses, revise your answer, handle changed constraints and compare attempts. It is not a live mock interview with a person. You can read the free sample before buying.

If you have a date for the loop, the 14-day senior mobile interview prep plan shows where practice like this fits. To see why the follow-up is where the round is decided, read the follow-up decides the senior mobile interview.

Sources

  1. Swift structures and classes.
  2. Swift language guide on automatic reference counting.
  3. Swift data race safety.
  4. Apple, Demystify SwiftUI.
  5. Apple, getting started with hang analysis.
  6. Swift Evolution SE-0306, actors (the actor reentrancy section).

Questions readers ask

© 2026 Mike Salari, Interview Runtime. All rights reserved. Quoting a short excerpt with a link to this page is welcome; republishing the article, in full or in part, is not.

Practice the follow-up, not the first answer.

Interview Runtime is the interview book plus 90 days of Guided Practice: you answer first, see the one gap that would cost the point, then answer again when one fact changes.