[-] UlrikHD@programming.dev 3 points 4 months ago

That should actually work great, in the absence of being part of the API, thanks! Funnily enough the copilot autocomplete suggested that when I was formatting the url param.

[-] UlrikHD@programming.dev 3 points 7 months ago

The person has previously been warned to stopped posting links to the site. They've now been given a temp ban, if that doesn't deter them, they'll be given a permanent ban and we might ban the site from our instance.

[-] UlrikHD@programming.dev 3 points 8 months ago

Nobody would ever say "Asian" when referring to the south east Asians powers though. Call it European colonial powers or something. It gets tiresome being lumped in with destruction caused by Britain, France, etc... when your own nation was nothing but potato farmers at the time.

[-] UlrikHD@programming.dev 4 points 9 months ago

programming.dev will migrate over to (lemmy compatible) Sublinks once it's ready, which will feature a different set of mod features. For that reason we will need new moderators to have an active programming.dev account. If you're willing keep an active user account on our instance let me know. We would prefer people we know will actively use their mod account to make sure reports are handled in a timely manner.

[-] UlrikHD@programming.dev 4 points 1 year ago* (last edited 1 year ago)

Personally I would recommend to use regex instead for parsing, which would also allow you to more easily test your expressions. You could then get the list as

import re
result = re.findall(r'[\w_]+|\S',  yourstring)  # This will preserve ULLONG_MAX as a single word if that's what you want

As for what's wrong with your expressions:

First expression: Once you hit (, OneOrMore(Char(printables)) will take over and continue matching every printable char. Instead you should use OR (|) with the alphanumerical first for priority OneOrMore(word | Char(printables))

Second expression. You're running into the same issue with your use of +. Once string.punctuation takes over, it will continue matching until it encounters a char that is not a punctuation and then stop the matching. Instead you can write:

parser = OneOrMore(Word(alphanums) | Word(string.punctuation))
result = parser.parseString(yourstring)

Do note that underscore is considered a punctutation so ULLONG_MAX will be split, not sure if that's what you want or not.

[-] UlrikHD@programming.dev 4 points 1 year ago

Stickied post would work just fine yeah, can't really expect the developer to set up a public repo for just tracking features. Hopefully Ruben takes notice.

[-] UlrikHD@programming.dev 4 points 1 year ago

Those doesn't break backwards compatibility though. Naturally you can't use match with a python 3.7 interpreter, but what scripts written for python 3.7 wouldn't work with a 3.11 interpreter?

I haven't encountered that issue before, so I'm curious what those problems OP have encountered looks like.

[-] UlrikHD@programming.dev 4 points 1 year ago

I assume you meant that both Rust and C compiles into machine code? Python compiles into bytecode that is then run in a VM, Rust and C usually doesn't do that as far as I know.

I was mostly curious if it was as easy as in C. Turun's reply answered that question though. Cheers.

[-] UlrikHD@programming.dev 3 points 1 year ago

Depends on the file, very simple files may only warrant npp, but VSCode for more complex stuff where live preview may come in handy.

[-] UlrikHD@programming.dev 4 points 1 year ago

Since it's variations of the combined ending, each permutation would count as unique. Meaning that 10 companions with 10 endings each would total 10.000.000.000 variations,

[-] UlrikHD@programming.dev 4 points 1 year ago

Whenever I click on the link it prompts me to register on kbin. Is it a closed off instance?

[-] UlrikHD@programming.dev 4 points 1 year ago

Got a Sony Xperia premium XZ from 2017 with the latest update being from 2019, android version 9

view more: ‹ prev next ›

UlrikHD

joined 1 year ago