Partitioned code into sections by function