Compose melodies adhering to the given motif and the outlined musical structure.
X:1
L:1/8
M:4/4
K:D
['D2 F/E/D FAdf', 'BAFA DFAd Afaf'  
X:1
L:1/8
M:4/4
K:D
|: A | D2 F/E/D FAdf | gefd edBd | A2 FA dfaf | g/f/e fd edBd | D2 F/E/D FAdf | g/f/e fd edBd | 
 A2 FA ABdf | afeg fdd :: e | f2 df edce | dcdA BAFA | DFAd Afaf | g/f/e fd edBd | 
 f/g/f df e/f/e ce | d2 dA BAFA | DFAd Afaf | afeg fdd :|  