input: Write a python function to implement a stack class with methods to push, pop, peek, and check if the stack is empty.
  ```python
  class Stack:
      def __init__(self):
          self.items = []
          
      def push(self, item):
          self.items.append(item)
  
      def pop(self):
          return self.items.pop()
      
      def peek(self):
          return self.items[-1]
          
      def isEmpty(self):
          return self.items == []
  
  # Test cases
  stack = Stack()
  assert stack.isEmpty() == True
  stack.push(1)
  assert stack.peek() == 1
  assert stack.isEmpty() == False
  stack.push(2)
  assert stack.peek() == 2
  assert stack.pop() == 2
  assert stack.pop() == 1
  assert stack.isEmpty() == True
output: class Stack:
      def __init__(self):
          self.items = []
          
      def push(self, item):
          self.items.append(item)
  
      def pop(self):
          return self.items.pop()
      
      def peek(self):
          return self.items[-1]
          
      def isEmpty(self):
          return self.items == []
  
  # Test cases
  stack = Stack()
  assert stack.isEmpty() == True
  stack.push(1)
  assert stack.peek() == 1
  assert stack.isEmpty() == False
  stack.push(2)
  assert stack.peek() == 2
  assert stack.pop() == 2
  assert stack.pop() == 1
  assert stack.isEmpty() == True