A Shropshire Lad contains several repeated themes. It is not a connected narrative, though it can be read as an allegory of a heart's journey through life. The "I" of the poems, the authorial person, is in two cases named as Terence (VIII, LXII), the "Shropshire Lad" of the title. However, the poems are not all in the same voice and the stories they tell are not intended as a single coherent narrative.
The collection begins by paying tribute to the Shropshire lads who have died as soldiers in the service of Queen Victoria, as her golden jubilee (1887) is celebrated with a beacon bonfire at Clee (I). There is little time for a lad to live and enjoy the spring (II). Death awaits the soldier (III-IV). Maids are not always kind (V-VI) and the farmer also comes to the grave (VII). Some lads murder their brothers and are hanged (VIII-IX). Love may be unrequited (X). A dead lad's ghost begs the consolation of a last embrace (XI). Unattainable love leaves the lad helpless and lost (XIII-XVI). The playing of a game of cricket or football consoles a broken heart (XVII).
The athlete who died young was lucky, for he did not outlive his renown (XIX). The poet exchanges a glance with a marching soldier and wishes him well, though thinking they will never cross paths again (XXII). He envies the country lads who die young and do not grow old (XXIII). Quick, while he is alive and young, allow him to work beside you! (XXIV). A lover may die, and his girl will walk out with another (XXV-XXVII). The hostility of the ancient Saxon and Briton are in his blood, and he owes his life to violence and rape (XXVIII). The storm on Wenlock Edge symbolizes the same turmoil in his soul as the Romans knew at Wroxeter (XXXI). He is here but for a moment â take this hand! (XXXII) But if he is of no use to them that he loves, he will go away, perhaps to be a soldier (XXXIV, XXXV). Or one may live an exile from home in London, but without forgetting home and friends (XXXVII, XXXVIII).
The wind sighs across England to him from Shropshire, but he will not see the broom flowering gold on Wenlock Edge (XXXVIII-XL). London is full of cold-hearted men who fear and hate one other, but he will make the best of life while he has a living will (XLIII). The suicide is wise, for he prefers to die cleanly than live in shame (XLIV). Bring him no flowers, but only what will never flower again (XLVI). A carpenter's son once died on the gallows, so that other lads might live (XLVII). He was happy before he was born, but he will endure life for a while: the cure for all sorrows will come in time (XLVIII). If crowded and noisy London has its troubles, so do quiet Clun and Knighton, and the only cure for any of them is the grave (L).
Though he is in London, his spirit wanders about his home fields (LII). From the unquiet grave the suicide's ghost visits the beloved (LIII). Those he loved are dead, and other youths eternally re-live his own experiences (LV). Like the lad that becomes a soldier, one can choose death and face it (LVI). Dick is in the graveyard, and Ned is long in jail, as he comes home to Ludlow (LVIII). Take your pack and go: death will be a journey into eternal night (LX). It matters not if he sleeps among the suicides, or among those who died well â they were all his friends(LXI). Do you mock his melancholy thoughts? He has used them like the poisons sampled by Mithridates, and shall die old (LXII). Perhaps these poems are not fashionable, but they will always please other lads like him (LXIII).

Question: Who died on the gallows?
Answer: The carpenter's son. 
Alternative answer: The soldiers