MCPcopy Create free account
hub / github.com/bspaans/python-mingus / get_range

Method get_range

mingus/containers/bar.py:151–160  ·  view source on GitHub ↗

Return the highest and the lowest note in a tuple.

(self)

Source from the content-addressed store, hash-verified

149 diff = 1 / cur - 1 / to
150
151 def get_range(self):
152 """Return the highest and the lowest note in a tuple."""
153 (min, max) = (100000, -1)
154 for cont in self.bar:
155 for note in cont[2]:
156 if int(note) < int(min):
157 min = note
158 elif int(note) > int(max):
159 max = note
160 return (min, max)
161
162 def space_left(self):
163 """Return the space left on the Bar."""

Callers 1

test_get_rangeMethod · 0.80

Calls

no outgoing calls

Tested by 1

test_get_rangeMethod · 0.64