Develop melodies according to the outlined musical structure, including the given motif.
X:1
L:1/8
M:4/4
K:G
['(3gag fg e2 dc', 'G2 ga bagf efga bagf e2 fg'  
X:1
L:1/8
M:4/4
K:G
 d>c | B>GD>G B>GD>G | (3gag fg e2 dc | BGDG BGDG | dcBc A2 dc | BGDG BGDG | (3gag fg e2 dc | 
 Bgfg ecAF | G2 B2 G2 :: ga | bagf efga | bagf e2 fg | agfe defg | agfe d2 ef | gfgd e2 dB | 
 cBAB cdef | gfgd ecAF | G2 B2 G2 :|  