CS 371: Module 3: Disjoint Set Data Structures

Module content developed by Professor Tralie. Module engine developed by Professor Tralie and Professor Mongan.


Please watch the two videos below, and click the Next button to continue when you're finished

Notes

  • In python, the boolean expression val in my_list will evaluate to True if val is an element of my_list, or False otherwise
  • In addition to lists, there are sets in python, which are declared using curly braces. For instance, x = {1, 2, 3}. The elements in sets are in no particular order. You can union one set with another by typing x | y