LGTM this is much clearer (and i think also better) than Mike's patch. https://codereview.appspot.com/8668044/diff/1/lily/skyline.cc File lily/skyline.cc (right): https://codereview.appspot.com/8668044/diff/1/lily/skyline.cc#newcode389 lily/skyline.cc:389: if (x1 > last_end) I suggest to add a comment: "Avoid creating zero-width empty buildings"