• 2 Posts
  • 98 Comments
Joined 1 year ago
cake
Cake day: October 19th, 2023

help-circle

  • This is not what I would consider a “political reason”. A political reason would be something like refusing to package it because of what political party Howard supports.

    There is plenty of software you’ll find in these repositories that aren’t under the GPL. CMake uses BSD, the Apache web server uses the eponymous Apache license, LibreOffice and Firefox use MPL, Godot and Bitcoin Core use the MIT license, and I’m sure there are plenty of other software licenses that I haven’t thought of yet.



  • You got downvoted here but you’re absolutely right. It’s easy to prove that the set of strings with prime length is not a regular language using the pumping lemma for regular languages. And in typical StackExchange fashion, someone’s already done it.

    Here’s their proof.

    Claim 1: The language consisting of the character 1 repeated a prime number of times is not regular.

    A further argument to justify your claim—

    Claim 2: If the language described in Claim 1 is not regular, then the language consisting of the character 1 repeated a composite number of times is not regular.

    Proof: Suppose the language described in Claim 2 is regular if the language described in Claim 1 is not. Then there must exist a finite-state automaton A that recognises it. If we create a new finite-state automaton B which (1) checks whether the string has length 1 and rejects it, and (2) then passes the string to automaton A and rejects when automaton A accepts and accepts when automaton A rejects, then we can see that automaton B accepts the set of all strings of non-composite length that are not of length 1, i.e. the set of all strings of prime length. But since the language consisting of all strings of prime length is non-regular, there cannot exist such an automaton. Therefore, the assumption that the language described in Claim 2 being regular is false.








  • It’s not really like they were evil about it though. Google attracted customers through its huge (at the time) 1 GB email storage space, which at the time, was unbelievably generous and also impressive in that it was offered for free. Outlook (Hotmail at the time) also drew in customers by offering the service for free, anywhere in the world, without needing to sign up for Internet service. Remember, at the time, e-mail was a service that was bundled with your Internet service provider.

    Into the mid-2000s and 2010s, the way that Gmail and Outlook kept customers was through bundle deals for enterprise customers and improvements to their webmail offerings. Gmail had (and arguably, still has) one of the best webmail clients available anywhere. Outlook was not far behind, and it was also usually bundled with enterprise Microsoft Office subscriptions, so most companies just decided, “eh, why not”. The price (free) and simplicity is difficult to beat. It was at that point that Microsoft Outlook (the mail client, not the e-mail service) was the “gold standard” for desktop mail clients, at least according to middle-aged office workers who barely knew anything about e-mail to begin with. Today, the G-Suite, as it is called, is one of the most popular enterprise software suites, perhaps second only to Microsoft Office. Most people learned how to use e-mail and the Internet in the 2000s and 2010s through school or work.

    You have to compare the offerings of Google and Microsoft with their competitors. AOL mail was popular but the Internet service provided by the same company was not. When people quit AOL Internet service, many switched e-mail providers as well, thinking that if they did not maintain their AOL subscription, they would lose access to their mailbox as well.

    Google and Microsoft didn’t “kill” the decentralised e-mail of yesteryear. They beat it fair and square by offering a superior product. If you’re trying to pick an e-mail service today, Gmail and Outlook are still by far the best options in terms of ease of use, free storage, and the quality of their webmail clients. I would even go so far as to say that the Gmail web client was so good that it single-handedly killed the desktop mail client for casual users. I think that today, there are really only three legitimate players left if you’re a rational consumer who is self-interested in picking the best e-mail service for yourself: Proton Mail if you care a lot about privacy, and Gmail or Outlook if you don’t.





  • No, what I said is true if you use zero-based numbering. But when communicating with others in English, the label “first” refers to the element with the smallest index. In zero-based numbering, the label “zeroth” refers to the element with the lowest index. It’s just not the default in English, but you can definitely use zero-based numbering in English if you’re willing to edit the configuration files.



  • My argument is purely pedantic. Pedantry is the lifeblood of programmer “humour”.

    I’m not arguing that we should adopt zero-based numberingin real-life human applications. I am arguing that in zero-based numbering, the label “zeroth” refers to the same ordinal as “first” in one-based numbering. I am poking fun at the conversion between human one-based numbering and computers’ zero-based numbering. That is why I am saying it should be called zeroth(); because human language should adapt to match the zero-based numbering their tools use. Whether I actually mean what I say—well, I leave that up to you.

    It does not matter why indexes start from zero in computing. The memory offset argument is only salient if you are using it as an argument for why computers should use zero-based numbering. It is not an argument against the properties of zero-based numbering itself.


  • Zero-based indexing redefines the meaning of the labels “first”, “second”, “third”, and so on. It adds a new label, “zeroth”, which has the same ordinal value as “first” in one-based indexing. The word “first” does not mean “the element with the lowest index” in zero-based indexing.

    If you are using a zero-based numbering system, you would absolutely say that array[2] is the final element in the array, that element having the ordinal label “second”, and yet the length of the array is 3 (cardinal). There is no fundamental connection between the ordinal labels “zeroth”, “first”, “second”, and “third” and the cardinal numbers 0, 1, 2, and 3. The similarities are purely an artefact of human language, which is arbitrary anyway. You can make an equally mathematically valid ordinal numbering system that assigns “third” to the element with the smallest index, “fourth” to the next-smallest, and so on. That ordinal numbering system is mathematically coherent and valid, but you’re just causing trouble for yourself when it comes time to convert those ordinals (such as array indexes) into cardinals (such as memory locations or lengths of fencing to buy).

    You can make an argument for why one-based numbering is more convenient and easier to use, but you cannot use the notion that zero-based numbering doesn’t make sense given the assumed context of one-based numbering as an argument for why zero-based numbering is invalid.

    I encourage you read up what is meant by “zero based numbering” because you and everyone else who has replied to me has tried to use “but that’s not how it works in one-based numbering” as an explanation for why I’m wrong. This is as nonsensical of an argument as trying to say i (the imaginary unit) is not a number because it’s not on the number line. It’s only not a number in the domain of the real numbers. Similarly, zero-based numbering is only nonsensical in the context of one-based indexing.

    It does not matter why indexes start from zero. The memory offset argument is only salient if you are using it as an argument for why computers should use zero-based numbering.


  • Okay, I will admit, you got me there. I did confuse indexing with numbering. From now on I will use the term “numbering” instead.

    It is entirely how ordinal numbers work in zero-based numbering. There is no “right way” for ordinal numbers to work. You can create a valid ordinal numbering system starting from any integer, or just some other ordered list. You cannot assume one-based numbering is “correct” and use it as an argument against numbering beginning from any other number.

    I encourage you read up what is meant by “zero based numbering” because you and everyone else who has replied to me has tried to use “but that’s not how it works in one-based numbering” as an explanation for why I’m wrong. This is as nonsensical of an argument as trying to say i (the imaginary unit) is not a number because it’s not on the number line. It’s only not a number in the domain of the real numbers. Similarly, zero-based numbering is only nonsensical in the context of one-based indexing.

    Zero-based numbering would number “foo” as the zeroth element, “bar” as the first element, and “baz” as the second element. “zeroth”, “first”, and “second” are labels representing ordinals. Your list has a length of 3 (which is a cardinal quantity unrelated to ordinals).

    Although, I would like to point out, it is perfectly valid to construct an ordinal labelling system that assigns “fifth” to the element with the lowest index, “sixth” to the next, and so on. That system is mathematically coherent but it is just troublesome to when it comes time to convert ordinal numbers (such as the index of the last fence-post) to cardinal numbers (such as the length of fence to buy).

    But this is now getting into the weeds of pure mathematics and most people here are engineers.


  • NateNate60@lemmy.worldtoProgrammer Humor@lemmy.mlOff by one solitude
    link
    fedilink
    arrow-up
    3
    arrow-down
    1
    ·
    edit-2
    2 months ago

    That’s because the word “first” in first() uses one-based indexing. In true programmer fashion it would have been called zeroth() but that is wholly unintuitive to most humans.

    I maintain that the element with the lowest index is called the “zeroth” element in zero-based indexing and “first” in one-based indexing. The element with index N is the Nth element.