I like the shrewd aspect of left pad of seeing if the interviewee asks questions about nebulous specifications, namely whether inputs longer than the pad length need to be trimmed
if you cannot write a left-pad, is-positive-integer, or isArray function in 5 minutes flat (including the time you spend Googling); then you don’t actually know how to code.