128. Delete the Last Node
Build the list, remove its last node, and print what remains.
If the list is empty, or becomes empty, print Empty.
Removing the last node is harder than removing the first, because you need the node BEFORE it — and a singly linked list gives you no way to step backwards.
Constraints - `0 ≤ n ≤ 100000` - `-1000000 ≤ value ≤ 1000000`
Input
The first line contains an integer n, the number of nodes.
The second line contains n space-separated integers — the node values from head to tail.
The starter code builds the list for you; work on the nodes, not the array.
Output
Print the resulting list from head to tail on ONE line, separated by single spaces, or Empty if no nodes remain.