Challenge 18 - Swap elements in a linked list
Given the head of a linked list and two values within the list, create a function that swaps the nodes with the given values. Your function should return the same list with the nodes swapped.
Input:
Elements:
Output: