Slightly more legible, fixed some bad logic in iterate concerning advertising.