Email deliverability basics in Digital Marketing - Time & Space Complexity
When sending emails to many people, it is important to understand how the process scales as the list grows.
We want to know how the time to deliver emails changes when the number of recipients increases.
Analyze the time complexity of the following email sending process.
for each email_address in email_list:
check if email_address is valid
send email to email_address
log delivery status
wait for server response
This code sends an email to each address in a list, checking validity and logging the result.
Identify the loops, recursion, array traversals that repeat.
- Primary operation: Looping through each email address to send emails.
- How many times: Once for every email in the list.
As the number of emails increases, the total time grows in direct proportion.
| Input Size (n) | Approx. Operations |
|---|---|
| 10 | About 10 email sends |
| 100 | About 100 email sends |
| 1000 | About 1000 email sends |
Pattern observation: Doubling the list doubles the work needed.
Time Complexity: O(n)
This means the time to send emails grows linearly with the number of recipients.
[X] Wrong: "Sending emails to more people takes the same time as sending to just a few."
[OK] Correct: Each email requires its own send and response, so more emails mean more total time.
Understanding how processes scale with input size is a key skill in digital marketing and technical roles alike.
"What if the emails were sent in batches instead of one by one? How would the time complexity change?"