If you mean the relative tuning string by string, it's mainly for ease of use. There have been (and still are) many, many different tunings available, but this one must have become the 'standard' because with it, most chords are available to be fingered without too much trouble.The fact that most of us have four fingers on the fretting hand probably played a part - when soloing, in open position, every chromatic note for more than two octaves is available without moving your fretting hand up or down. In fretted position, it's still easy to play as such, with only a one fret move.
This 5-fret difference could have been continued onto the top strings, but would make barre chords pretty difficult. However, that pattern does go up, and down, with 5 , 6, 7 and even 8 string basses.
If you're asking about why have E as the lowest note, more difficult to say, except that it roughly follows the male human voice range (I'm talking open strings here, for all the castrati out there ! )
It could have been tuned in 5ths as violins are, but they need to be, as they only have four strings, with a much shorter string length making it difficult to play, say, up to its '24th fret' .