There are actually two points here:
1) It reduces the number of executions of statements from 6 to 1. I'm not sure if this is faster in practical terms, but theoretically it should be. At least it makes the code cleaner and more understandable.
2) If this code is executed in a browser, the car object is added to the DOM because it is added to the window object.
This code will warn "LOL":
var foo = "LOL"; alert(window.foo);
source share