Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Update sortedlist.py
Added time complexity for the '__len__()' method.
  • Loading branch information
Greeshmanth1 authored Mar 8, 2024
commit 538c4011db6360f6a702fce05b9da1627862b23b
4 changes: 3 additions & 1 deletion src/sortedcontainers/sortedlist.py
Original file line number Diff line number Diff line change
Expand Up @@ -1076,7 +1076,9 @@ def __len__(self):
"""Return the size of the sorted list.

``sl.__len__()`` <==> ``len(sl)``


Runtime complexity: `O(1)`

:return: size of sorted list

"""
Expand Down