input: Write a python function to check if a value is contained in a linked list.
  assert contains(head, 15) == True
  assert contains(head, 42) == True
  assert contains(head, 7) == False
  assert contains(head, 23) == True
  assert contains(head, 50) == False
output: class ListNode:
      def __init__(self, value=0, next=None):
          self.value = value
          self.next = next
  
  def contains(head, value):
      current = head
      while current:
          if current.value == value:
              return True
          current = current.next
      return False