code: def get_first_duplicate(items):
      seen = set()
      for item in items:
          if item not in seen:
              seen.add(item)
          else:
              return item
      return None
  
file_path: plotly.py/packages/python/chart-studio/chart_studio/utils.py
imports: from __future__ import absolute_import
  import os.path
  import re
  import threading
  import warnings
  import json
  from _plotly_utils.exceptions import PlotlyError
  from _plotly_utils.optional_imports import get_module
label_desc: Use image node_id 5 for calling a global function with example usage: get_first_duplicate(items) and returns: None, item