Vulwsztyn

joined 2 years ago
[–] Vulwsztyn@programming.dev 1 points 2 days ago* (last edited 1 day ago)

it's as easy as the code you're maintaining is.

it has fewer guardrails than most languages, that would prevent you from writing shit code

[–] Vulwsztyn@programming.dev 1 points 2 days ago

syntax is bad for list operations, also there are situations where you need to count the number of parentheses you closed, which wouldn't happen of you were able to use fluent interfaces

[–] Vulwsztyn@programming.dev 1 points 6 days ago

do you have an example of this?

[–] Vulwsztyn@programming.dev 3 points 2 months ago

This is only a Draft for now though

[–] Vulwsztyn@programming.dev 1 points 2 months ago

Yeah, but you can also write it like I proposed which is less boilerplaty and gives the same advantages

 

Hi, I recently realised one can use immutable default arguments to avoid a chain of:

def append_to(element, to=None):
    if to is None:
        to = []

at the beginning of each function with default argument for set, list, or dict.

[–] Vulwsztyn@programming.dev 3 points 2 years ago* (last edited 2 years ago) (2 children)

Read the 1st comment under 1st link, 2nd link os about something different, 4th links is about something absolutely different. **