I always did it like this, I have no idea why. First classes, then fields, then functions. Maybe because it leaves classes near the class :).