Author: Lead by code
Mar 13, 2025 iOS
iOS interview question
What is difference between opaque , generic and Any? In Swift, opaque types, generic types, and Any are different ways of handling type abstraction. Here’s how they differ: 1. Opaque Types (some) Opaque types allow you to specify a return…
Feb 26, 2025 study Material
GCD for main and Global Thread
GCD (Grand Central Dispatch) GCD (Grand Central Dispatch) is a Low level API basically used to manage the concurrency of the application. It manages the heavy task at the background. We use DispatchQueue for the operation for the GCD .…
Feb 17, 2025 iOS
SwiftUI ViewModifier and ViewBuilder Interview Questions
Here are some advanced interview questions on ViewModifier and ViewBuilder in SwiftUI, along with answers and explanations. 🔹 ViewModifier Interview Questions 1. What is the purpose of ViewModifier in SwiftUI? How does it differ from normal View extensions? Answer: A…
Feb 17, 2025 iOS
iOS interview question on struct and Classes
Here are some commonly asked questions and answers on Struct vs. Class in Swift: 1. What is the primary difference between struct and class in Swift? Answer:The main difference is that structs are value types, whereas classes are reference types.…
Feb 16, 2025 iOS
Core Data Intrview question
Here are some commonly asked Core Data interview questions, categorized for different levels of expertise. Basic Questions What is Core Data in iOS? Core Data is Apple’s framework for managing an object graph and persisting data in an iOS/macOS app.…
Jan 21, 2025 iOS
What is the role of @State, @Binding, @ObservedObject, and @EnvironmentObject in SwiftUI? Provide examples.
@state @State in SwiftUI is a property wrapper used to manage simple, local state within a single view. It enables the view to update its UI whenever the value of the @State property changes. Key Characteristics of @State Local State:…
Jan 01, 2025 iOS
DSA Two Pointer Approach
The two-pointer approach is a versatile technique in Data Structures and Algorithms (DSA) used to optimize problems that involve linear traversal of arrays, lists, or strings. Here's a detailed explanation of when to use it and its applications: When to…
Jul 26, 2024 interview
iOS Developer interview question UILabel, UITextField, UIButton
Basic UIKit Components (UILabel, UITextField, UIButton): - Explain the role of UILabel in iOS applications. UILabel is a fundamental UI component in iOS applications used for displaying static or dynamic text. It provides a way to present text content to…