First, "day" is sung with a melisma (B A), musically giving something of a sense of duration (for "all"). Second, "night and day" is a merism.
I referenced Chuck Berry's original and found that the Beatles changed the lyrics slightly (from Berry's "I'm gonna learn to dance if it takes me all night and day") and that they added the melisma to "day."