SwiftUI vs UIKit interview questions

15 real SwiftUI vs UIKit questions from the Swift bank, as asked in Indian campus drives and tech interviews. Every question has a verified answer and an AI-tutor explanation on placd — free to start.

1. What is Declarative UI?

Junior
  1. A.describing what the interface should look like for a given state rather than imperatively mutating views
  2. B.a wrapper for a view's private mutable source of truth that triggers a redraw when changed
  3. C.a lightweight value type whose body describes a piece of the interface and is recreated on updates
  4. D.the older imperative framework that builds interfaces from mutable view-controller objects and view hierarchies
Reveal the answer + AI explanation — free account

3. Which statement is correct?

Junior
  1. A.Declarative UI — a wrapper for a view's private mutable source of truth that triggers a redraw when changed
  2. B.Declarative UI — a wrapper giving a child view read-write access to a value owned by its parent
  3. C.Declarative UI — describing what the interface should look like for a given state rather than imperatively mutating views
  4. D.Declarative UI — a lightweight value type whose body describes a piece of the interface and is recreated on updates
Reveal the answer + AI explanation — free account

4. What is @State?

Mid
  1. A.a wrapper for a view's private mutable source of truth that triggers a redraw when changed
  2. B.a wrapper giving a child view read-write access to a value owned by its parent
  3. C.describing what the interface should look like for a given state rather than imperatively mutating views
  4. D.the older imperative framework that builds interfaces from mutable view-controller objects and view hierarchies
Reveal the answer + AI explanation — free account

6. Which statement is correct?

Mid
  1. A.@State — a wrapper for a view's private mutable source of truth that triggers a redraw when changed
  2. B.@State — describing what the interface should look like for a given state rather than imperatively mutating views
  3. C.@State — the older imperative framework that builds interfaces from mutable view-controller objects and view hierarchies
  4. D.@State — a wrapper giving a child view read-write access to a value owned by its parent
Reveal the answer + AI explanation — free account

7. What is @Binding?

Mid
  1. A.a wrapper giving a child view read-write access to a value owned by its parent
  2. B.a wrapper for a view's private mutable source of truth that triggers a redraw when changed
  3. C.describing what the interface should look like for a given state rather than imperatively mutating views
  4. D.the older imperative framework that builds interfaces from mutable view-controller objects and view hierarchies
Reveal the answer + AI explanation — free account

9. Which statement is correct?

Mid
  1. A.@Binding — the older imperative framework that builds interfaces from mutable view-controller objects and view hierarchies
  2. B.@Binding — a wrapper giving a child view read-write access to a value owned by its parent
  3. C.@Binding — describing what the interface should look like for a given state rather than imperatively mutating views
  4. D.@Binding — a lightweight value type whose body describes a piece of the interface and is recreated on updates
Reveal the answer + AI explanation — free account

10. What is View struct?

Junior
  1. A.a wrapper giving a child view read-write access to a value owned by its parent
  2. B.a wrapper for a view's private mutable source of truth that triggers a redraw when changed
  3. C.a lightweight value type whose body describes a piece of the interface and is recreated on updates
  4. D.describing what the interface should look like for a given state rather than imperatively mutating views
Reveal the answer + AI explanation — free account

12. Which statement is correct?

Junior
  1. A.View struct — describing what the interface should look like for a given state rather than imperatively mutating views
  2. B.View struct — a lightweight value type whose body describes a piece of the interface and is recreated on updates
  3. C.View struct — a wrapper for a view's private mutable source of truth that triggers a redraw when changed
  4. D.View struct — a wrapper giving a child view read-write access to a value owned by its parent
Reveal the answer + AI explanation — free account

13. What is UIKit?

Junior
  1. A.the older imperative framework that builds interfaces from mutable view-controller objects and view hierarchies
  2. B.describing what the interface should look like for a given state rather than imperatively mutating views
  3. C.a lightweight value type whose body describes a piece of the interface and is recreated on updates
  4. D.a wrapper giving a child view read-write access to a value owned by its parent
Reveal the answer + AI explanation — free account

15. Which statement is correct?

Junior
  1. A.UIKit — a wrapper giving a child view read-write access to a value owned by its parent
  2. B.UIKit — a wrapper for a view's private mutable source of truth that triggers a redraw when changed
  3. C.UIKit — a lightweight value type whose body describes a piece of the interface and is recreated on updates
  4. D.UIKit — the older imperative framework that builds interfaces from mutable view-controller objects and view hierarchies
Reveal the answer + AI explanation — free account

Free to start

Answers, AI explanations, and a scored voice mock interview

Sign up free to check your answers with explanations, ask the AI tutor anything on any question, and take one full AI mock interview — scored like a real panel.

Practice SwiftUI vs UIKit free