Correct. The four words - melody, territory, canopy, and army – follow the same rule while forming the plurals (by changing –y into –ies). (Rule: If the singular noun ends with -y and the -y has a consonant before it, change the -y into -ies to form the plural.) Thus, the plural forms of these words are – melodies, territories, canopies and armies. The word ‘valley’ is the odd one here since it ends with –y but has a vowel before the -y. In such a case, the plural is formed by simply adding –s to the singular noun.