RSSAmplifier

Blog

TIL with Mohammad

Recent content on TIL with Mohammad

mfaani.comRSS feed ↗68 posts

Latest posts

A Framework to Make Decisions Faster as a Lead Software Engineer

A practical guide for lead engineers to make faster, better-informed decisions under pressure.

How to Use Git Worktree? And How It's used by AI Agents?

How does git worktree work and how it helps AI agents work faster and without conflicts

When to Use AGENTS.override.md?

You'd usually use an AGENTS.override.md for ad hoc purposes

xcodebuild for AI

I’m running into some issues with the project setup Claude came up for me and I’m triaging it now. It’s using xcodebuild which prompted me to write this post. Prerequisite Highly recommend to acquaint yourself with the following definitions: Project Target Scheme Action Destination Product For that see my stackoverflow answer to: Xcode: What is a target and scheme in plain…

How the mental cost of AI can be reduced over time and type of usage?

Why every AI guardrail shouldn't be just about cost, privacy and security but emotional well being, plus the inflection point that reduces asking questions and begins increasing AI delegation, anchoring (through the usage of specs) and joy.

Part 1 - State Drive Nagiation: Overview

Why direct view-to-view navigation breaks down at scale, and how a state machine with a dedicated navigation layer creates maintainable, testable mobile apps.

Part 2 - State Driven Navigation: Tutorial

Dead simple, concrete examples of state-driven navigation. Build a 3-screen onboarding flow from scratch.

What does actor reentrancy mean?

If you captured any state before doing some async work in your actor, then by the time your task is resumed, your captured state may be stale. This is what actor reentrancy is about. Because of this, you should avoid capturing things that are subject to change before your task is suspended. Instead, only retrieve values after your task is resumed. The term “reentrant” literally means…

Systems Design - Pagination

How does Base 64, cursor collision, security, deletion of a cursor all come together, caching and stale data management

High Level Anatomy of a Camera Capturing Session

I used the following tutorial series from Apple on ‘Capturing and Displaying Photos’. They’re great. Just that it took me a bit to be able to piece together how components from AVFoundation work together. Working with AVFoundation isn’t really the kind where you read documentation and then can piece things together. It’s complicated. You might understand an individual…

What Is a Suspension Point In Swift?

Ever wondered what is getting suspended when Apple says 'suspension point'?

Live Activities Part 1 - Problem Statement

A laundry list on Live Activity challenges

Live Activities Part 2 - The missing doc

Let's answer some lesser discussed architectural questions about Live Activities

Live Activities Part 3 - Development

Some tips for developing live activities and understanding its architecture

Live Activities Part 4 - Debugging

Sharing some tips on how to troubleshoot cases where tokens aren't getting updated or payload isn't getting updated. Or often payload is delivered but dropped by the app.

Live Activities Part 5 - The Update Token Problem

Key product decisions that may help to achieve a better Live Activity User Experience

Swift Actors: few random notes

Curious about why Swift's thread-safety mechanism is called an 'actor'? This post explores the origin of the name, clarifies common misconceptions, and explains why actors are about more than just asynchronous programming. Discover when to use actors in your Swift code and how they fit into the broader concurrency landscape

Interviewing - Final Round Learnings

Discuss all aspects of interview

Symmetric Tree

A good tree traversal excercise

Separate Devices, Better Life: Why Personal Freedom Beats Using Your Work MacBook

Why having your own personal laptop is a game changer

How to Get Into Software Engineering

most people think you need to study four years to get a job in tech. That's not true

Why Can't You Loop Over Ranges of Characters in Swift

Why are Swift Character ranges different from Integer ranges

How Quantifying Impact Helps Your Career Growth

Often as engineers we do ourselves a disservice and just do the hard work without measuring its impact. This post gives you strategies to promote yourself

How Do Binaries work together? What breaks ABI?

Ever wondered what how two binaries interface with one another? Which changes impact ABI and which don't?

Some vs Any

What's the difference between some and any? Why do they both exist? Which should I prefer using?

Hugo Post Formatting Basics

How to use frontmatter, shortcodes, make changes to your theme, do syntax highlighting

Hugo High Level

How does Hugo work? How are things structured? What are the main building blocks of Hugo?

Being First is a Game Changer

Being a good lead is a lot about being first

The effect of direction on recursion and understanding code - Longest Common Subsequence

Solve a fun challenged named 'Longest Common Subsequence' by learning how the direction in recursion can effect your perception but also make comparing code difficult

Asteroids Collision

Of the most fun leetcode challenges I've ever done

How Many Envelopes Can You Fit Into Another?

Learn how to solve a challenging problem from LeetCode using dynamic programming and binary search. Find the longest increasing sequence of envelopes that can be nested inside each other.

Longest Increasing Subsequence Length

Learn how to calculate the longest increasing subsequence. The differences of this with other tree based algorithms and more

Tips for post creation

Discussion about when you should start blogging, the importance of getting early feedback and how to get it, how to market your posts and more

Tree Basics and some Swift helpers for leetcode

Some gotchas with different kinds of trees, tree mappings and traversals

How Can I Inspect the Size Impact of Symbols in an App Binary: A Practical Guide for Apple Developers

Learn how to use nm to count extra symbols that impact App Size

Optimizing Binaries - How Does the Linker Help Reduce App Size? What are the different types of linking - Part Two

In this post I go through some of differences between the two linkers, their impact on app size and how we should be considerate of stripping symbols

Optimizing Binaries - How Does the Linker Help Reduce App Size? What are the different types of linking - Part One

In this post I extract all the good chunks from Apple's fantastic session on linker and how it does things to reduce app size. I also discuss some of the difference between Compiler and Linker

Optimizing Binaries - Build Pipeline Jargon

Jargons and Examples of the Xcode Build Pipeline

Optimizing Binaries - High Level Xcode Build Pipeline

Ever thought what happens under the hood when you build your app?

Whats the Difference Between an App (bundle) and a Binary

How the their internals are different and where they're used

The power and expressiveness of Swift ranges

Ranges in swift are super simple to create. Yet they come in various forms. let r1 = 1...3 let r2 = 1..<3 let r3 = ...3 let r4 = 3... let r5 = ..<3 They all have range like characteristics, but have slightly different traits. It&rsquo;s because they&rsquo;re actually different types. Different Range Types let r1 = 1...3 // ClosedRange<Int> let r2 = 1..<3 // Range<Int> let r3 = ...3 //…

How cp case-insensitivity can cause chaos!

How cp ends up being dangerous...!

How to Think Recursively - Part 2

How to break down a recursive question into smaller pieces. Sophisticated Question.

How to Think Recursively - Part 1

How to break down a recursive question into smaller pieces. Easy Question

Why does pod lib lint suddenly fail to build?

Why might pod lib lint fail to build while the app itself builds fine?

How Understanding State Machines Helps With Building Trees and Graphs

A different way of seeing tree explorations

What Resources Does Apple Provide for teaching iOS to students?

Buried deep under Apple's K-12 resources?

Which Way Am I Sorting?

Ever confused as to what the end result of your sorting is?

Recover Binary Tree

How do you fix a broken binary tree?

How to Calculate the Middle Index?

Are middle indexes always actually the middle index?