skysight-inc/HackerNews huggingface dataset:
> The humble state machine is a more important part of programming
> than people like to admit

Here is where I feel a lot of OOP applications are “doing statefullness wrong.” Everyone gloms onto the popular GoF patterns, but explicit state machines are not nearly popular enough.

A colleague once remarked that in business programming, every model should be a state machine until you can demonstrate you can do without. For example, many Ruby on Rails models have a concept of validation. Most such models can be greatly improved by treating “invalid” as an explicit state with its own methods and behaviours distinct from the methods and behaviours of a valid model (which may encompass other states as well).

I find that if you’re going to have state, go all the way, reify it, make it something you can name and manipulate. Implicit state is the GOTO-ridden spaghetti-code of imperative programming style.
Dog owner to sue family who found and kept her missing pet
Pretty cool. I'd like to know more about the design decisions. Why registers? Why those specifically? And more.
I actually work daily on my Asus thin desktop (very similar specs). I run Ubuntu though. The fact that my mini pc makes almost zero noise is great and it does feel good to be a bit greener with the power savings. Funny thing is that I got the Asus to test webapps (I do mostly front-end). I use the browser's dev tools to emulate slower Internet connections but I don't know how to emulate slow processors/tiny RAM (maybe there is a way?). After a while I just never went back to my laptop, tweaked Ubuntu to make the Asus faster and more capable and ended up coding on it for good. Now, if my apps do well on the Asus they fly on 'average' hardware.
Neither of those two are particularly difficult.
But do you need the VM for something specific, is it part of some philosophical/aesthetic guideline, or is it just something fun to do?
But if the bottleneck is publication, not data gathering, then why does the Chinese government bother cracking down on map making activities?

> Three British geology students discovered this the hard way while “collecting data” on a 2009 field trip...
Quite, yeah.

But if the author's goal was maximum readability, they might have considered doing away with the abbreviations.
Also the novel 'Flashman' is quite good really.
This is What I See
It looks normal on the surface, doesn't it? The new normal, with constant war, epidemics and crisis; but still you wouldn't suspect.

The controllers of this planet are all busy setting up the board for the end game, that's why the volume is constantly being turned up. They don't even mind giving away a few crumbles of truth here and there to keep us occupied until it hits us in the face. That's why no one cares about Fukushima, why everyone swears the economy is fine while the stock market is crumbling; when they all start lobbing nukes at each other it won't matter. Russia is preparing the bomb shelters from the Cold War in all of a hurry, why now all of a sudden?

This isn't about us, at all. They would prefer most of us dead. You have to be either stupid or ignorant if you haven't connected the dots by now. I know it's an uncomfortable feeling, but do you truly believe pretending will take us out of here? This is their sick re-enactment of the delusional Armageddon myth the master psychopaths cooked up long ago. Whoever is left standing gets to have their way with whatever remains of the planet and humanity when it's over, that's the deal.

What did you expect? Seriously? When you leave psychopaths with unlimited power and no oversight? You would never, ever, cut any one else that much slack; give any one else that much benefit of doubt. So where's the disconnect? Why are you so unable to stare truth in the eyes when it comes to the enslavement and rape of earth and humanity? Do you truly believe pretending will get us out of here?

This is it, the moment of truth. Do we step up and earn our freedom, or do we watch the psychopaths burn it all to the ground?
Thanks for the suggestion, we very well might do so. The line does add something for the cases where a topic is becoming less neutral (stronger language is being used, either positive or negative) but it's unfortunate that the scales are quite different on the whole. We're going to work on making the system more intuitive and find better ways to highlight the most interesting trends.
You forgot a couple options:

3) Available code

4) Familiar code

The history of the software industry has basically been 40 years of customers choosing code that exists, solves their problem right now, and doesn't make them think too hard about how to use it. They choose this over correct code (hence, Microsoft) and over fast code (hence, Python/Ruby/Javascript/PHP).

FP actually helps you write both fast and correct code. The problem is that it requires a good deal more planning up-front and more effort to change things when requirements change. This has usually been a non-starter with the majority of customers: they want software that does what they need it to do, right now, and will continue to do what they need it to if they change their mind. If it screws up occasionally or makes people wait, that's okay, it's still faster & more accurate than a human is.
> They speculate that it could be malformed, or a hybrid of a blue whale and another species.

Are there whale species that have calls significantly higher than 50 Hz? Any ungulate experts here who can comment?
What sort of graphics/audio interface do you expose to the program?

(The project is very cool! The instruction set reminds me a bit of the MIPS subset usually implemented in uni courses.)
It has! Almost all major languages today let you pass functions (and closures with captured bindings) as values.
Less code is generally better. But I've noticed a lot of folks still using ^ or $ when what they really mean is \A or \z
I think there's a market for something in this form factor that's a bit more powerful than the ultra-cheap options. Enough that you don't have to think about performance as a limitation quite so much.
This applies to projects and businesses run by a couple of individuals, not startups or fast growing companies.
I think "it's hard to read code in a language you don't know."

You're fooled on this because so many languages are so similar -- if you know C++, you can trivially read Java and C# and Python, and even languages that are a bit further afield like Javascript and Perl still are heavily influenced by C, so don't seem too odd.

But Scheme is a whole new family of languages. It's like being an English reader and looking at Greek text as opposed to Spanish. It's not that Greek is harder than Spanish, it's that Spanish is closer to what you already know.
Not necessarily. For some people, the best day is one where they don't have to do any work whatsoever.
Hi fellow Hamiltonian!
4. You best read code by trying it out and seeing what pieces of it do.

Try it with an interpreter running.
I see the map of this whale's migration pattern goes north and south along the north american coast. Is it following an alternating current?
Three years to build a ship, three hundred to build a tradition
If we can track it, is it possible to locate the whale and observe it?
Perhaps this is (at least) a 4th possibility, which is that it would take you time to get used to, but once you had it would not be too much for you. Even Paul Graham (enthusiastic Lisp advocate) once said "I suppose I should learn Lisp, but it seems so foreign" [1]

I found it reasonably readable. The only criticism I had, offhand, was that the predicates like 'is-piece-knight?' were a bit verbose: the query mark at the end is understood to label a predicate, so the 'is-piece-' was redundant. I'd have written 'knight?' instead. That's pretty nit-picky though, and I don't think the current convention really detracts from its readability.

[1] If Lisp is So Great: http://paulgraham.com/iflisp.html
Not "taken over" but in many ways functional programming techniques have gotten big in front-end land, not only with JavaScript but also "real" functional languages like Elm or ClojureScript.
Bad data set. You are missing most of the free wifi spots in my town, but do show a number of people who just haven't secured their routers.
> so you wouldn't have to write 20 lines of hard to grasp code with bytes.Index(), bytes.HasSuffix(), bytes.TrimRight(), etc., like people do in Go

Go has regexps, and a very good implementation at it.

Depending on what you do and on the specific code-path, compiling and/or executing a regexp might be slower than manually parsing the string. Go standard library is pretty concerned with performance (much more than Python's or Ruby's, for instance), so it tends to avoid regexps.
It's been about 15 years[1] since I last spent a lot of time with Scheme, but yes. As others have mentioned, the author could've done a better job with variable names, and syntax highlighting would do a world of good, but the code itself looks pretty understandable.

If you're not using DrRacket, then please start using it. I learned what was then Scheme from SICP[2], but I've heard that the Little Schemer is perhaps a bit more approachable. Try starting with it[3].

[1] That moment when you realize it's been over fifteen years since you started college...Yeesh.

[2] https://en.wikipedia.org/wiki/Structure_and_Interpretation_o...

[3] http://stackoverflow.com/questions/13003850/little-schemer-a...
Engineers of Jihad: Connection between Violent Extremism and Education
4. The syntax is unfamiliar.
Will a Drying Up of Tech Capital Lessen Inequality?
Yep, although I only use Common Lisp, this is still readable to me.

A couple of things could be improved for me; I almost never use abbreviated variable names unless it's for simple iteration.

Also things like this being repeated on 8 lines, just screams for some sort of abstraction:

(set! rsc (+ rsc 3)) (set! rsc (+ rsc 0))) (set! rsc (+ rsc 0))
Reminds me of the plot of Star Trek IV: The Voyage Home!
I don't think the issue here is that it requires work to upgrade across multiple major versions. Rather, it is that "two major versions back" is only about 1.5 years ago, and that major building blocks got abandoned in the mean time.

If you have projects that do not see any updates for a few years (fairly common, in my experience), then see urgent requests come in (in this example, it was that a Chrome update broke the app, but it might also be a feature request. Normally, those shouldn't require upgrading technology to new versions, but there may be security fixes that didn't get backported, or it may no longer be feasible to get people who know how to use that 'ancient' version), that can get annoying fast.

Lesson learned should be that one should not blindly use the latest, shiniest, technologies, but take longevity of the product into account. Problem for web-based stuff is that there is not really a stable product that one can count on to be around mostly unchanged in a few years time, and that is best in class or at least close to it. Evolution is just too rapid.
Of course you can interact with two monitors at once. I do it every day.

My current standing desk setup is an MBPR15 on top of a wine case on my desk, with a ViewSonic 24" 4K display to the left, hanging in portrait mode on the Amazon Basics version of an Ergotron arm. Best dev rig I've ever had!

Quite often I'll put docs and references on the external monitor while I write code in Visual Studio or IntelliJ on the Mac's display. This works especially well with the monitor in portrait mode.

Then I leave the mouse cursor over on the external display and use two-finger scrolling there, while using the keyboard in the editor window.

If this isn't interacting with two monitors at once, I don't know what is. And it's a huge improvement over a single monitor.
I think it's perfectly acceptable for project maintainers to provide rpms, debs, ppas, etc. as long as those artifacts are organized in largely the same way that distro maintainers would organize them. (I doubt any distro maintainers would disagree.) I don't think it's a good idea to pack lots of already-distro-packaged libraries into those artifacts. Building for many distro formats is a pain, but I doubt that building this new format in a universal way will be easy either. If you have a different AppImage for each distro/version combo, is that an improvement?

For the packages you've mentioned, live active projects with maintainers who can produce this distribution format but can't deal with apt, maybe the giant ball of wax is okay. I won't be installing anything this way, but clearly I'm not the target user. It seems certain, however, that in future we'll be hearing about lots of vulnerabilities attributed to AppImages linking in old library versions.
That's not really what functional programming is about. Functional programming is more about avoiding state and referential transparency. Most programmers do not attempt to do this in mainstream programming languages.
You once again missed my point, the students i am looking to hire are well versed in AI tech, know a lot about the field, and can hit the ground running (vs some entitled prick who thinks he deserves the job). Broad-brushing I know, but only as a counterpoint to your own.
I believe the high firmware failures rates only effected a relatively small number of models.

Hopefully firmware will get to a point where if the SSD does fail it will be far more graceful (revert to read-only), rather than the sudden death I've seen first hand.
I use clojurescript to interact with React. Luckily with a small community we aren't overrun by build tools! I've recently taken up the boot[1], and it's amazing. I'm able to quickly get up a live-reloadable environment wherein I can actually _understand_ what is going on.

cd my_project
boot dev

'boot dev' is a task that's defined in the project's build.boot file. It compiles the cljs files to a main.js file, and serves it from a specified directory.

Any edit to a cljs file triggers a recompile (of that namespace only - takes about 0.1 second). If the recompile is unsuccessful then a buzz sound plays. If the recompile is successful, boot will play a nice subtle ding sound, and reload the main namespace. With immutable datastructures everywhere, arranging the app's state to allow reloading is simple.

How simple? There's a fantastic tutorial about how to setup everything I've just described at: [2].

This template will spit out all the code needed for the live-reload-cljs thing [3]. Once you install boot (with 'brew boot-clj' it's on apt-get too), You can run it with

boot -d seancorfield/boot-new new -t tenzing -a +reagent -n boot-cljs-project
cd boot-cljs-project
boot dev
;; then edit the cljs file.

[1] http://boot-clj.com

[2] https://github.com/magomimmo/modern-cljs/blob/master/doc/sec...

[3] https://github.com/martinklepsch/tenzing
There is no such thing as a `foveated display`

There is foveated rendering: a rendering optimization technique where you render at higher resolutions where the eye is looking at due to higher visual acuity in a small ~5-degree circle thanks to a large concentration of cones in the fovea of the eye.

This has nothing to do with the actual pixel density of HMDs. Physical pixel density remains an issue, and foveated rendering does not solve that.

edit: Perhaps I misunderstood, are you talking about retinal laser projected displays and concentrating the beam on the fovea?
Yes, although I'm not sure why they had to use single letter symbols to identify the different types of chess pieces. Also it seems like they could've applied the DRY principle a bit with all of those conditionals. Also the use of set! is a little bit ugly.
People say this and it's not really true.

Scheme has mutable state. Scheme has unmarked side-effects. Scheme has variables, as opposed to tags applied to constant values.

Scheme was an entirely new kind of language back when lambda expressions were Heavy Deep Magic and dynamic typing was something you did when your Flexowriter was well-oiled (hyperbole intentional). These days, it's no weirder than Javascript or the more modern dialects of Java or Visual C#.Net. Hell, even C++ is getting lambdas and closures, and that's a Serious Business COBOL-Replacement Language.

Modern Algol dialects are Scheme in everything except syntax, and now that metaprogramming (Ruby, to begin with) is beginning to catch on, I fully expect language designers to re-invent some shambolic version of s-expressions when they realize that metaprogramming in Algol syntax is hard.

Scheme won. It's just that its victory was suppressed for political reasons.
Maybe the Victorians just weren't good at humour? I was thinking maybe we don't get them because they are old but Mark Twain lived pretty much over the Victorian period (Twain 1845-1910, Victoria's reign 1837-1901) and he's pretty funny.

He didn't seem to think so much of England at the time - “I would like to live in Manchester, England. The transition between Manchester and death would be unnoticeable.”
Gallery of Processor Cache Effects
avoiding global/shared state :) we are not avoiding state as per se. State if super important! That's why we care about it so much. But Im just nitpicking, sorry
I really like this idea in theory. But in practice, even the given example is kind of broken. Would a random Ghana man be able to survive in the US? How much training and teaching would it take for them to actually be successful? Our culture and daily life are really not that similar. Undoubtedly there would still be a lot of economic gain for him, but the sheer logistics of it don't seem possible to overcome.
> scientists in general are not trustworthy

You don't know that.
1. From glancing at it: this is a pretty ugly solution.

On the plus side: It's minimal and doesn't spend much time building abstractions on top of the basic lists/etc. that scheme provides. However, it certainly isn't pretty.

For instance: Things like the king & knight checks are really pretty ugly brute force solutions.

Similarly, the variable & function naming really is rather unclear and very poorly commented--some of that may be use of things idiomatic to scheme that I'm unfamiliar with though.

2. Always a possibility, I certainly don't know you. ;)

3. Some people certainly have said that before and probably will again. This is really just a personal preference thing, I think.
Graphical interfaces pushed OOP into the mainstream. As plain structured programming was not powerful enough to create GUIs, people were forced to learn it.

The fact is, for an industry that talks so much about lifelong learning and innovation, software developers are very conservative.
http://research.microsoft.com/en-us/news/features/vibe.aspx
Looks like for just general use the research points to you being incorrect.
Regarding the module dependency woes, check out Carton (https://metacpan.org/pod/Carton).
Other funny facts from the same table (from the site, the image seems to be outdated)

- Bernie Sanders is 3rd overall, ahead of Jeb Bush, Ben Carson and Marco Rubio.

- Larry Lessig got more money from the "weapon makers" than Rick Perry and Bobby Jindal put together.

- Barack Obama got more than Chris Christie, despite not actually running for POTUS in 2016.

http://www.opensecrets.org/industries/recips.php?ind=D&cycle...

(I put "weapon makers" in quotes since, obviously, Defense includes more than weapons.)
In fairness he explicitly says he is trying to explain why it's not popular. Not why it's not a gold thing to learn. He days it's a good thing to learn at the end of the article.

The reason he says it's not popular is because the vast majority of people think imperatively when dealing with a problem that involves state and time. They might think functionally when trying to express an immutable law or when categorising the qualities of a horse or whatever. But when doing something that involves changing the state of the world in time and space (which is a significant part of many programs) they think imperatively. And even C will support enough of the functional stuff to do the rest (see Numerical Recipes, for example)
I wonder if it's really a whale, or some sort of man-made source (possibly a classified military technology) that coincidentally happens to be particularly whale-like?
5 steps to building your brand with Slack
Because it doesn't have enough advantages to justify the added complexity.
I meant "hidden" state because functional programs still reason about state, but more explicitly. In a functional style you can't just call a function that relies on hidden state somewhere, you have to pass that state in!

But with partial application and currying you could pass the state in at any point in the program, so all the functions on the inside are pure, while state exists on the edges.
Google is quite famous for running their data centers hotter than others.

* Title makes it obvious, but 95f : http://www.geek.com/chips/googles-most-efficient-data-center...

* Increased in dns request failures(likely due to said heat) and bad routing cause internal iGoogle services to request this guy's stuff: https://www.youtube.com/watch?v=aT7mnSstKGs
those are both javascript? thought you were going to say haskell or clojure...
Agreed. It got so bad, that at work I ended up becoming part of the problem and wrote my own isomorphic router for React[0]

[0] https://github.com/studionone/react-isorouter
I can somewhat make sense of that code, but the code of function ch-hof is a bit hard to read - and the function name is not helping. I guess he's trying to see if the king is under check, and if so by which piece(s).

Also I notice code like:

(- (cdr kpos) 1))

How is that possible? If kpos is a list of two elements to represent the king's position, so (cdr kpos) should be a list, not compatible with subtraction.

For example:

#;4> (- (cdr '(1 2)) 1)

Error: (-) bad argument type: (2)
I can't tell if this is sarcasm or not, but I appreciate it either way.
No I use it for more than that, the landing page is built on Bootstrap, so I have modals and other fun stuff that Bootstrap + jQuery bring to the table.
This makes a mockery of shared libraries. The technical debt will accrue and run unfathomably deep. Security failures due to currency issues are simply the most obvious. The insoluble mystery bugs of mismatched dependencies will plague application developers that choose this distribution strategy.
extremely testable, easier to reason about, automatically dry, parallelizable, automatically reusable, memoizable, composable, can be analyzed with some theoretical systems, and most important- you get stuff that works better (in my experience)
True but you don't want to answer that in an interview.
Sure he did.
> you can easily now do just about everything on "Vanilla JS" as you can using jQuery.

jQuery is vanilla JavaScript. As a full stack JavaScript developer, it pains me that people think that something written in JavaScript isn't vanilla JavaScript. It is.
Main argument according to reviews is the gap between aspiration and achievement that occurs when engineers' expectations of success are not met is what drives many of us, apparently, to join extremist groups.

The explanatory and predictive power of, "just sore losers" seems weak.

A review of the book (FT, paywalled) summarized other arguments about polarized, binary thinking, and an inability to accept culture, ambiguity, and a lot of what I see as sanctimonious bullshit the way non-STEM students do.

Defense of any principles (right, left, or religious) is considered extremist and dangerously reactionary these days.

One would hope that before laying the critical foundations to discredit educated conservatives (who largely take STEM degrees), academia might dedicate some thought to resolving why there are people with debt-funded $100k+ graduate degrees who read horoscopes, Piketty, and can't calculate a tip.
but good programmers? yes.