• 0 Posts
  • 21 Comments
Joined 2 years ago
cake
Cake day: July 17th, 2023

help-circle
  • Create a python file that only contains this function

    def increase_by_one(i):
        # this increments i
        f=open(__file__).read()
        st=f[28:-92][0]
        return i+f.count(st)
    

    Then you can import this function and it will raise an index error if the comment is not there, coming close to the most literal way

    Any code which does not contain the comment “this increments i:” will produce a compile error and fail to run.

    could be interpreted in python



  • dont_lemmee_down@lemm.eetoComic Strips@lemmy.worldThey/Them
    link
    fedilink
    arrow-up
    1
    arrow-down
    1
    ·
    edit-2
    1 month ago

    Well it kinda is. Pronouns are like names, in the sense that we use them to describe to whom we refer.

    They are a non injective function on the name set.

    The restriction you would like to make is that the function is not multivalued. But it is. As an example, Andrea is a name that is usually associated with a female person, but it is a normal name for male people in Italy.

    We allowed people to be named whatever they wanted (or their parents wanted), so why not also let them choose whatever pronoun they prefer?


  • dont_lemmee_down@lemm.eetoComic Strips@lemmy.worldThey/Them
    link
    fedilink
    arrow-up
    1
    arrow-down
    2
    ·
    1 month ago

    If you’re with Dan (they/them) and Dan (he/him), you would also have the problem when saying

    “I was with Dan and Dan the other day. Dan hadn’t brought the poster, so Dan went back to the car to get it.”

    So to avoud confusion, people should not be allowed to be called Dan anymore. In fact everyone gets a UUID so there is no more confusion.



  • Calling people what they ask to be called just doesn’t have to be this difficult.

    We in fact do it all the time. It’s just people have gotten used to using names. But it’s not like you were born with a Dave chromosome. Your parents decided to call you Dave, so in the end it’s also just a made up name/sound.






  • I have been running Linux for some time now, still had a Windows partition for gaming. Then I switched the motherboard and windows decided I no longer had a key for it… I stopped playing most of the windows exclusive games. Since last week I can’t even boot anymore, something about missing drivers. Spent a day trying to fix it. Today I decided fuck it and I’m just leaving it behind! It makes no sense wasting so much energy on a vastly inferior OS that actively tries to fight me.




  • AFAIK someone is working on it. But the problem is the high dynamics of public transport. Routes and schedules get changed quite often, schedules might be quite irregular (think only Sunday at 3:14). And all that data has to be stored offline. Stops might be changed do to construction work for a week. And that is in the optimal case: In some countries the bus comes when it comes, and stops if it wants to stop.

    Currently you can see where the lines of a bus or the metro go, but that’s about it, I think.


  • They will never do, because they are not trying to. AFAIK no one is trying to build FOSS reviews of restaurants/stores, no one is building street view and no one is saving where you live to make the one click from work to home route planning. For me, those are not functions that I need (or want). I need a map that works offline, does route planning (offline) and allows me to display multiple GPX files at the same time.

    Does OSMAnd have all that? It does, so for me it’s an alternative. What use case do you have?


  • The thing is, OSM is not comparable with GoogleMaps. OSM is just a (gigantic) database and is in many cases way more complete than GoogleMaps. What people usually associate with OSM is a rendered version of the database focused on what ever the renderer decided: bike lanes, waterways, hiking trails, etc. Many other apps actually use their database: OrganicMaps, Komoot, etc. And even more their rendered tiles. Now there are so many functionalities that this database doesn’t do like geocoding (searching for adresses), reverse geocoding (getting the adress of a point) or route planning, but there are tools for it build on OSM data. e.g. Nominatim does geocoding and graphhopper does routing.

    And to be honest, if you’re travelling by bike graphhopper does a way better job at routing than google. An other plus, you can download the complete data for offline usage. All of Europe is only around 60GB.



  • It’s quite weird actually: You vote for a party and a local candidate. The local candidate get’s into parlament directly while the rest of parlament is filled proportionally to the general cast vote if they manage to get over 5% of the votes (this does not apply to direct winning candidates or recognized minority representing parties). With parliament resizing to accomodate for at least your direct candidates to represent your percentage. Which always made me wonder, if everyone votes for just Party A’s direct candidates, but they get 0% of the general vote, would all other parties then have to get infinite extra positions? That would result in an infinitely big parliament, which basically means every citizen is now in parliament, and kinda get’s around the fight over universal basic income, right?