Quantcast
Channel: Delphi – The Wiert Corner – irregular stream of stuff
Viewing all articles
Browse latest Browse all 1445

Reminder: see if I can implement megabool in Delphi (or at lest trilean)

$
0
0

Now that I re-wrote my 2012 talk on Class Operators and Helpers and presented it in Delphi at the ITDevCon2024 ([Wayback/Archive] ITDevCon | Home – Rome, 2024), see [Wayback/Archive] GitHub – jpluimers/ITDevCon2024: Temporary ITDevCon2024 repository until I fixed the «git checkout “Illegal byte sequence”» of my Conferences repository, here is an idea to check out if I can implement it in Delphi:

[WaybackSave/Archive] goosewin on X: “you should add megabool to your projects …”

[Wayback/Archive] Gb4v6EPX0AA8JiJ.jpg (303×318)

This was a wildly popular screenshot in November 2024 on social media (not just Twitter or [Wayback/Archive] John Vandivier | Edge cases be like join our community: https://ladderly.io | Instagram) but, according to what I could find, originated from this February 2024 thread on [Wayback/Archive] Hash Tables | MetaFilter:

There are booleans and then there are probabilistic booleans.

As a computer nerd, I know what you are a talking about, but I just have to make this joke:

enum megabool {
  TRUE,
  FALSE,
  NEITHER,
  BOTH,
  MAYBE,
  TRUEISH,
  FALSEISH,
  IT_DEPENDS,
  OSCILLATING,
  ITS_COMPLICATED,
  DOUBLE_TRUE,
  DOUBLE_FALSE,
  ...

posted by [Wayback/Archive] DreamerFi’s profile | MetaFilter at 3:31 AM on February 12, 2024 [9 favorites]

Or maybe I should start with Three-valued logic (some call this troolean, others trinary, trivalent, ternary, or trilean storing the internal values in either of these two forms:

Then I might extend it to values consisting of multiple trits, and doing conversions to/from string and integer plus of course various operations to cover as many operators as possible.

Query: [WaybackSave/Archive] enum “megabool” – Google Search

Inspiration for a few operators: [WaybackSave/Archive] GitHub – RobTillaart/Troolean: Arduino Library for a three state logic datatype supporting {True False Unknown}

--jeroen


Viewing all articles
Browse latest Browse all 1445

Trending Articles