PayPal's interview question on "Caching Headers (s-maxage directive)" appears in their Online Assessment for Backend Engineer roles, focusing on HTTP caching mechanics.
This is typically a multiple-choice question testing understanding of the Cache-Control: s-maxage directive, tagged under Backend, HTTP, and Caching. It presents a scenario where an API response includes a caching header like Cache-Control: s-maxage=3600 (or similar with x-max-age variant in some recollections), then asks which statements are true about its behavior in shared caches (e.g., CDNs, proxies) versus private caches (e.g., browsers).[1][2]
The core concept: s-maxage specifies freshness lifetime only for shared caches, overriding max-age or Expires if present, but is ignored by private caches. No coding is required; it's conceptual.[3][1]
Common options (reconstructed from candidate experiences) include:
s-maxage applies to shared caches but not browsers. (True)[5][1]max-age in proxies/CDNs. (True)[7][1]max-age for all caches. (False—shared only)[7]Example header: Cache-Control: public, s-maxage=86400, max-age=3600. Shared caches hold for 1 day; browsers use 1 hour.[5]
No code, inputs, or outputs—pure theory. No explicit constraints mentioned, as it's not algorithmic. Assessed via selecting 1+ correct options from 4, within HackerRank's timed OA (e.g., 90-120 mins total).[2]