Live data from Hacker News

The Good, the Bad and the GUI

haskell.org

1–10 of 47 posts

Re: The Good, the Bad and the GUI

#2
That appalled user would have a heart attack at Awk, a language in which a previously unseen variable serves as zero or an empty string.

   count++    # if count doesn't exist, it becomes 1
A previously unseen array reference materializes automatically too:

   count[$1]++
(I think this is garbage too, but it leads to throwaway programs that are very concise. If you write anything large, it's going to bite you on the butt:

   mispelled[foo] += bar; # wee

Re: The Good, the Bad and the GUI

#4
In every language I know there is a set if conventions around Null values, not set values, true, false and zero

We have only had the concept of zero for a thousand years and null for about fifty. Expecting there to be a common way of handling this in all domains and industries is a bit much and expecting it to be handled the way the OP prefers is highly unlikely (although I do agree with their opinion)

If the convention in accountancy is BLANK == 0 then that's their convention. Implement it using a single method that's nice and easy to instrument and discover for later on, perhaps raising warnings out to the reports produced.

Leave the worrying over not set values for when Unicode and UTC handling in excel is brought up :-)

Re: The Good, the Bad and the GUI

#5
I personally would prefer a spreadsheet that treated null as the identity for whatever function it was acting as an input to (0 for addition, 1 for multiplication, e for exponentiation, Identity matrix for matrix multiplication, etc.), only throwing an error when a null does not resolve to a single value (i.e. the same cell is used for both addition and multiplication). But that would apparently require me to smoke some stuff.

Re: The Good, the Bad and the GUI

#6
I continue to be terrified at how spreadsheets are used in business applications. Squashing data that shouldn't be in tables into tables "so you can work with them" was the worst thing we ever taught non-programmers to do. We should have taught them how to program instead.

(you can get close to programming in a spreadsheet if you know what you're doing with Insert > Name > Create, and one day I'd like to see a spreadsheet that lets you write your macro functions in Python rather than VB, but nobody is taught to use Excel that way except people who also program.)

Re: The Good, the Bad and the GUI

#7

I was particularly impressed by this detail further down the conversation: Let A1 = 1, A2 = blank, A3 = 3 PRODUCT(A1:A3) is 1 A1 * A2 * A3 is 0

Well that's just inconsistent and annoying and wrong.

I think the original comments are still over the top, as it seems to be arguin that a defined convention exists but the OP disagreed with it.

However if your example is what they were actually complaining about then hell yes.

Re: The Good, the Bad and the GUI

#8
This is a cultural issue. Most business I know see a program telling you data is invalid just means the program is annoying and getting in the way.

They want the program to just assume you know what you are doing.

This is what they want, so this is what they get.

Re: The Good, the Bad and the GUI

#9

I continue to be terrified at how spreadsheets are used in business applications. Squashing data that shouldn't be in tables into tables "so you can work with them" was the worst thing we ever taught non-programmers to do. We should have taught them how to program instead. (you can get close to programming in a spreadsheet if you know what you're doing with Insert > Name > Create, and one day I'd like to see a spread…

Anecdotally, trillions of dollars daily are moved around through chains of excel spreadsheets. It's been an eye opener for me :-)

Re: The Good, the Bad and the GUI

#10
I get it, I really do. But I'm a programmer.

Spreadsheets are the dominant end-user-programmable tool in existence. Much of what people user them for is horrifying to programmers who know better.

But if spreadsheets actually did the "right" thing, they would never have been so widely adopted in the first place. That's an unprovable assertion on my part, but I strongly suspect it's true. I think it's a clear case of Worse is Better[0].

[0] https://en.wikipedia.org/wiki/Worse_is_better

Post reply on HN