MCPcopy
hub / github.com/keon/algorithms / test_plus_one_v2

Method test_plus_one_v2

tests/test_array.py:276–282  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

274 self.assertListEqual(plus_one_v1([9, 9, 9, 9]), [1, 0, 0, 0, 0])
275
276 def test_plus_one_v2(self):
277
278 self.assertListEqual(plus_one_v2([0]), [1])
279 self.assertListEqual(plus_one_v2([9]), [1, 0])
280 self.assertListEqual(plus_one_v2([1, 0, 9]), [1, 1, 0])
281 self.assertListEqual(plus_one_v2([9, 9, 8, 0, 0, 9]), [9, 9, 8, 0, 1, 0])
282 self.assertListEqual(plus_one_v2([9, 9, 9, 9]), [1, 0, 0, 0, 0])
283
284 def test_plus_one_v3(self):
285

Callers

nothing calls this directly

Calls 1

plus_one_v2Function · 0.90

Tested by

no test coverage detected