Still I dont get what problem you are facing. Its just the delete of a node from a link list then I have already given a code snippet to achieve the same and you can customize it to add extra information like short link and long link. Mine is just a simple where only one pointer exists and thats short link according to your problem and that is the next node.