Paul McCartney wrote the song while the Beatles were in Rishikesh, India, studying Transcendental Meditation.
In his 1984 interview with Playboy, McCartney said: I wrote that as a kind of Beach Boys parody.