Better HN
topnewbestaskshowjobs
Log inSign up

panic

29,749 karma · joined Sep 16, 2009 (17y ago) · 3,593 submissions

Submissions

1351.

Introduction to Programming with Shift and Reset (2011) [pdf](pllab.is.ocha.ac.jp ↗)

3 points · by panic · 8y ago · discuss

comment 8y ago · link · parent

> Lisp and Haskell are arguably the most peculiar languages out there, at least they are from my experience.

Clearly the author has yet to encounter HOtMEfSPRIbNG!

1353.

APL at Its Core(ac1235.github.io ↗)

77 points · by panic · 8y ago · 14 comments

comment 8y ago · link · parent

Yeah, that's what I was thinking of too. Don't relax in the tub too long or the doors will unlock!

comment 8y ago · link · parent

The sensors have a lot more failure cases, though, and it can be hard to tell whether they're working properly.

comment 8y ago · link · parent

You can address bytes (using instructions like i32.load8_u), but doing arithmetic with them can be awkward.

comment 8y ago · link · parent

Sure, but there's no standard ABI for WebAssembly yet. I'm basically just saying we need an ABI before we can target it as a platform apart from the web.

comment 8y ago · link · parent

I'm also excited about this aspect of WebAssembly, but interoperability will hard without a well-defined ABI. There are only four types in wasm: int32, int64, float32, and float64. Anything other than that needs to be encoded somehow, either as multiple values or in memory.

For example, say you want to pass a 16-byte struct as an argument: how do you do it? Do you store the struct in memory and pass an int32 pointer to its start address? Or an int64 pointer? Maybe you encode it as two int64s? Once you've made a choice, good luck calling functions generated by a compiler that made a different one!

Another problem (in the web context) is blocking--Emscripten runs into this one. You can't suspend WebAssembly execution in the middle of calling out to an imported function. If a WebAssembly program wants to read keypresses interactively, it can't use a blocking function like read(). You have to pass the keypresses in at the outer level--or reimplement the call stack yourself like Go did (https://docs.google.com/document/d/131vjr4DH6JFnb-blm_uRdaC0...).

In general, WebAssembly code today is very tied to the JavaScript code that manages its interaction with the outside world. You can't just write a WebAssembly program that uses OpenGL. You also need to write the JavaScript that turns those calls into WebGL calls. I don't think this is a fundamental problem--we just haven't seen standards develop yet. As platforms start to define their API directly in terms of WebAssembly, without a JavaScript layer, we may see more of a "standard ABI" develop. Until then, it's hard to know what kind of APIs to target or support as an application or compiler writer.

comment 8y ago · link · parent

Especially now that we all use navigation apps in our cars.

1360.

Finding and exploiting hidden features of Animal Crossing’s NES emulator(jamchamb.github.io ↗)

2 points · by panic · 8y ago · discuss

comment 8y ago · link · parent

Check out the paper "Difficulty Rating of Sokoban Puzzle": https://pdfs.semanticscholar.org/880f/32f843e8e1fe9c712b0fc4... -- in particular the "problem decomposition" model introduced at the end. Being able to break a solution into subproblems makes it easier, even if there are a lot of steps (see Figures 5 and 6 in the paper).

1362.

The Excel Depression (2013)(nytimes.com ↗)

3 points · by panic · 8y ago · discuss

comment 8y ago · link · parent

So, if I wanted something to turn into a different item, where's the syntax for it?

    [ >  Player | Crate ] -> [  >  Player | > Rock  ]     
What if I want something to slide over multiple tile spaces? Where's the syntax for this?

    [ >  Player | Crate | ] -> [  >  Player | | > Crate ]
What if I want the item to progressively become more difficult to move, say for instance if I'm moving a snowball. Where's that syntax?

You'll have to explain what "more difficult" means to answer that one!

comment 8y ago · link · parent

Another tricky one by Stephen: https://www.puzzlescript.net/play.html?p=bf3272fd7b73c43acb4...

1365.

Post correspondence problem(people.ksp.sk ↗)

1 points · by panic · 8y ago · discuss

comment 8y ago · link · parent

> A theorem is a program we run on our wetware, and if a given wetware runtime doesn’t support the memory or time requirements for a theorem, it won’t run correctly.

You can use a theorem without "running" it, though. The classification of finite simple groups took thousands of pages to prove; it would be pretty inconvenient if you had to read all those pages to use the theorem!

1367.

The Future of Computing: Logic or Biology (2003) [pdf](lamport.azurewebsites.net ↗)

126 points · by panic · 8y ago · 47 comments

comment 8y ago · link · parent

Related (from 2011): http://worrydream.com/ABriefRantOnTheFutureOfInteractionDesi...

comment 8y ago · link · parent

Many people who hit kids aren't making fine distinctions like that. The whole point of the research is to address the general practice.

comment 8y ago · link · parent

Yeah, the research is pretty clear on this. From https://www.ncbi.nlm.nih.gov/pmc/articles/PMC3447048/:

> Although some studies have found no relation between physical punishment and negative outcomes, and others have found the relation to be moderated by other factors, no study has found physical punishment to have a long-term positive effect, and most studies have found negative effects.

comment 8y ago · link · parent

He has a completely valid argument—Friday can be excluded (that wouldn't be a surprise), Thursday can be excluded (since he already excluded Friday, it wouldn't be a surprise), and so on, until the last day left is Monday. So he can conclude the execution must be on that day.

(In fact, he has a valid argument for anything he might want to believe since the original statement made by the judge is self-contradictory.)

comment 8y ago · link · parent

One way to think about this paradox is as a game with two players—a prisoner and an executioner. The game progresses over five turns, representing the days of the week.

On each turn, the prisoner secretly chooses whether or not they expect to be killed on that day. Then the executioner chooses whether or not to kill the prisoner. The game ends on the turn the executioner decides to kill the prisoner. If the prisoner wasn't expecting to die, the executioner wins; otherwise, the prisoner wins.

The important detail here (which is obscured by the logical perspective) is when the prisoner is allowed to expect to die. If they're allowed to expect their death on every single day, the prisoner can just do that and win automatically. If they can only expect to die once, there's a situation the usual paradoxical argument doesn't consider: that the prisoner has survived until Thursday but has already used their chance to expect to die. In this case, they know they're going to die on Friday, but there's nothing they can do about it.

comment 8y ago · link · parent

I like this article's focus on technology as a way of helping skilled people do their job more effectively. Why shouldn't a business owner be able to use Bash and SQL to run their business? Maybe the solution isn't new technology, but training people to use the old stuff.

1374.

Ask HN: Your independent research?

3 points · by panic · 8y ago · discuss

1375.

VTaiwan: Public Participation Methods on the Cyberpunk Frontier of Democracy(civichall.org ↗)

2 points · by panic · 8y ago · discuss

1376.

Monte Carlo Integration in 1D(blog.demofox.org ↗)

3 points · by panic · 8y ago · discuss

comment 8y ago · link · parent

This is an extension of the earlier Sketch-n-Sketch system by the same group: http://ravichugh.github.io/sketch-n-sketch/

It looks like you can try it (including the Deuce additions) here: http://ravichugh.github.io/sketch-n-sketch/releases/v0.6.3/

1
454647
120