Update backtracking/coloring.py

Co-authored-by: Christian Clauss <cclauss@me.com>
This commit is contained in:
Hardik Pawar 2024-10-01 08:22:15 +05:30 committed by GitHub
parent 9da28b0ccc
commit 42c32e7c4e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -125,7 +125,7 @@ def util_color(
def color(graph: list[list[int]], max_colors: int) -> list[int]:
"""
Attempts to color the graph with at most max_colors colors such that no two adjacent
Attempt to color the graph with at most max_colors colors such that no two adjacent
vertices have the same color.
If it is possible, returns the list of color assignments;
otherwise, returns an empty list.