input: Write a python function to implement a basic version control system with commit and restore functionalities.
  assert vc.commit()==1
  assert vc.restore()==[]
  assert vc.commit()==2
output: class VersionControl:
      def __init__(self):
          self.history = []
          self.current_version = []
  
      def commit(self):
          self.history.append(list(self.current_version))
          return len(self.history)
  
      def restore(self):
          if self.history:
              self.current_version = self.history[-1]
          return self.current_version
  
  vc = VersionControl()