Live data from Hacker News

Code is run more than read

olano.dev

101–110 of 325 posts

Re: Code is run more than read

#101
post #23

"biz > user" is valid on paper because someone has to pay for the party; there are a finite number of software devs and capitalism is great at allocating scarce resources where they're most needed. Or at least the "spherical cows" version of free-market capitalism is great at that. In that version of capitalism, if your OS spends too much time putting spam in the Start Menu and not enough on fixing bugs, you can just…

Just because this doesn’t happen instantaneously doesn’t mean it’s a fantasy. Large changes in an ecosystem always take time. It may be years before the incumbents are truly displaced, but that doesn’t mean they won’t be. MySpace and RIM also seemed like they’d be there forever.

"In the long run, we're all dead."

Re: Code is run more than read

#102
post #88

Earlier quoted context omitted.

Likewise, TIL. In your link however it states "Example 1: Numerical Context Let's consider two real numbers, a and b. If a is neither greater than nor less than b, but they aren't explicitly equal, the relationship is ≹" How can that be possible?

It is false - real numbers fulfill the trichotomy property, which is precisely the lack of such a relationship: every two real number is either less than, equal or greater than. But the numerical context can still be correct: (edit: ~~imaginary~~) complex numbers for example don’t have such a property.

i'm learning about this right here as I read, but do you mean complex numbers rather than imaginary?

Re: Code is run more than read

#103
post #33

TIL of ≹, which "articulates a relationship where neither of the two compared entities is greater or lesser than the other, yet they aren't necessarily equal either. This nuanced distinction is essential in areas where there are different ways to compare entities that aren't strictly numerical." ( https://www.mathematics-monster.com/symbols/Neither-Greater-... )

Reminds me of the concept of games in combinatorial game theory, they are a superset of surreal numbers (which are themselves a superset of the real numbers) in which the definition of the surreal numbers is loosened in a way which looses the property of they being totally ordered. This creates games (read weird numbers) which can be "confused with" or "fuzzy" with other numbers, the simplest example is * (star) which is confused with 0, i.e. not bigger or smaller than it, it's a fuzzy cloud around zero (notated 0║*). More complex games called switches can be confused with bigger intervals of numbers and are considered "hot". By creating numbers from switches you can create even more interesting hot games.

Re: Code is run more than read

#104
post #88

Earlier quoted context omitted.

Likewise, TIL. In your link however it states "Example 1: Numerical Context Let's consider two real numbers, a and b. If a is neither greater than nor less than b, but they aren't explicitly equal, the relationship is ≹" How can that be possible?

It is false - real numbers fulfill the trichotomy property, which is precisely the lack of such a relationship: every two real number is either less than, equal or greater than. But the numerical context can still be correct: (edit: ~~imaginary~~) complex numbers for example don’t have such a property.

As I've written in another comment here, a great example of a number-y field which is not totally ordered is Games ⊂ Surreal Numbers ⊂ ℝ. There you have certain "numbers" which can can confused with (read incomparable) whole intervals of numbers. Games are really cool :)

Re: Code is run more than read

#105
post #57

Earlier quoted context omitted.

That depends on the application and the use case, but good performance and good readability aren't mutually exclusive. Easy to read software might not always be the most performant, but it's far easier to improve performance in an easy to read codebase than it is to make a hard to read but performant codebase easier to read.

Yeah, that's right. I just feel that latency is sometimes missing from the discussions re. developer efficiency vs paying more for compute.

Yep. Theres a huge experiential difference between something happening instantly and it happening in 200ms or so. Especially when typing or playing video games.

Re: Code is run more than read

#106

Earlier quoted context omitted.

Likewise, TIL. In your link however it states "Example 1: Numerical Context Let's consider two real numbers, a and b. If a is neither greater than nor less than b, but they aren't explicitly equal, the relationship is ≹" How can that be possible?

I think they mean the case where a and b are variables for which you don't know the values.

Yeah, that's how I understood it. E.g one might write

  (a+b)^2 != a^2 + b^2
To mean that in general the equality doesn't hold. Despite exceptions like a=b=0

Strictly you should write something like

  ¬[∀ a,b  (a+b)^2 != a^2 + b^2]
But shorthand and abuse of notation are hardly rare

Re: Code is run more than read

#107
post #88

Earlier quoted context omitted.

It is false - real numbers fulfill the trichotomy property, which is precisely the lack of such a relationship: every two real number is either less than, equal or greater than. But the numerical context can still be correct: (edit: ~~imaginary~~) complex numbers for example don’t have such a property.

i'm learning about this right here as I read, but do you mean complex numbers rather than imaginary?

Yep, that’s what I meant, sorry!

Re: Code is run more than read

#108
post #93
post #86

Earlier quoted context omitted.

How can the sum of a bunch of positive powers powers of 2 be a negative number? Isn't the sum of any infinite series of positive numbers infinity?

The infinite sum of powers of 2 indeed diverges in the real numbers. However, in the 2-adic numbers, it does actually equal -1. https://en.wikipedia.org/wiki/P-adic_number

Eh, P-adic numbers basically write the digits backwards, so "-1" has very little relation to a normal -1.

Re: Code is run more than read

#110
post #88

Earlier quoted context omitted.

It is false - real numbers fulfill the trichotomy property, which is precisely the lack of such a relationship: every two real number is either less than, equal or greater than. But the numerical context can still be correct: (edit: ~~imaginary~~) complex numbers for example don’t have such a property.

i'm learning about this right here as I read, but do you mean complex numbers rather than imaginary?

Same question.

Or more generally, vectors. They don't have a total order, because as we define "less than"/"greater than" in terms of magnitude (length), this means for any vector V (other than 0), there's an infinitely many vectors that are not equal to V, but whose length is equal to length of V.

Is this is what ≹ is talking about?

Post reply on HN