Solve each chemical element for the number of valence electrons indicated by its atomic mass and use that answer to determine the color of each section. For example hydrogen has 1 valence electron so wherever you see "H" use the number color 1 which is yellow.