Brantley Harris

Brantley Harris

2 thoughts; 1 stream
last posted Oct. 21, 2014, 1:29 a.m.
0

Web / Python programmer out of Chicago. I focus on design and learning theory applied to computer science.

Chicago, IL
Joined on Oct. 20, 2014, 4:02 a.m.
get recent cards as: atom

Python Dynamic Type System idea

@constrain(name=str, value=int_between_0_and_100)
def foo(name, value):
    pass


def foo(name, value):
    """    
    Where:
        - name (unicode)
        - value (int): > 0, < 100
    """

@alt(foo)
def foo(name, coef):
    """
    Where:
        - name (str)
        - value (float): > 0
    """
2 thoughts
updated Oct. 21, 2014, 1:29 a.m.
2 thoughts
updated Oct. 21, 2014, 1:29 a.m.

Streams by this user that have been favorited by others.

No favorited streams yet.

0

Python Dynamic Type System idea

@constrain(name=str, value=int_between_0_and_100)
def foo(name, value):
    pass


def foo(name, value):
    """    
    Where:
        - name (unicode)
        - value (int): > 0, < 100
    """

@alt(foo)
def foo(name, coef):
    """
    Where:
        - name (str)
        - value (float): > 0
    """
4 years, 8 months ago
0

I should not attempt the perfect stairway to the top of each mountain. Get to the top, then build a staircase if time allows.

Thoughts by this user that have been liked by others.

No liked thoughts yet.