Catalog PyPI
PACKAGE EXPLORERView in registry

afivmax

PyPI

Interview problem of Ant Fin

Versions collected1
Direct dependencies0From release 0.3.0
Last observed20 Oct, 21:07 UTC

README

Version 0.3.0 documentation

afivmax

Build Status PyPI version Coverage Status Documentation Status

安装

pip install afivmax

使用

from afivmax.afivmax import afiv_max
# args
assert 3 == afiv_max(1, 2, 3)
assert 3 == afiv_max(3, 3, 3)


# args with key
assert 3 ==afiv_max(1, 2, 3, key=lambda x: x ** 2)
class TmpClass:
    def __init__(self, x):
        self.val = x
assert 9 == afiv_max(*[TmpClass(x) for x in range(10)], key=lambda x: x.val).val


# iterables
assert 3 == afiv_max([1, 2, 3])
assert 3 == afiv_max([3, 2, 1])
assert 3 == afiv_max([3])

# iterables with keys
assert 3 == afiv_max([1, 2, 3], key=lambda x: x ** 2)
assert 9 == afiv_max([TmpClass(x) for x in range(10)], key=lambda x: x.val).val

# iterables with default
assert 10 == afiv_max([], default=10), "iterable with default only"

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Versions 1

Collected releases
VersionPublishedDirect dependenciesOpen version
0.3.027 Jun 20190

Package advisories

0
No matching advisories collected

This describes our collected data; it is not a security assessment.

Repository

PENDING
eggachecat/afivmax

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 20 Oct, 21:07 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package:6eb5f4ec5e4aac8b7db52338fa7179ccbd31d1b913505bc14ad430264681d6c4