skysight-inc/HackerNews huggingface dataset:
If you have a stack machine, when you write a function like this.

function foo() {
let x = 1;
let y = 2;
x + y;
}

Your code already depends on ordering. x is on the stack first. y is on the stack second.

You don't randomly rewrite this two lines of code on every invocation of foo.

`let x = 1` and `let [x] = useState(1)` is the exact same thing.
Not sure I follow, you mean cancer is a byproduct of being unwanted?
Why interview questions for programming jobs are so difficult?
https://github.com/js/mobility-name-generator
This is why I read Hacker News. Awesome pet project! Well done!
Echoing you concern and somehow related: in Germany it is almost impossible to get state of the art software infrastructure on the road for customers of public transit because of the fragmentation of transportation providers. Municipalities run their own systems and while not all of them are actively sabotaging attempts at increased coherence, none of them has any incentive to increase coherence either.

If it weren't for the state-run federal railway system, that runs also commuter railways in all German cities (and thus can enforce pressure) I reckon there would even be no software to calculate a ride from one end of the country to the other. And there would certainly be no product like the BahnCard, were you can use all of Germany's public transit for ~4.200 € / year.
No, my point is that it does not parallel that. Also, I think that people who say that did not read the book at all, but found slavery mentioned in book analysis and jumped to conclusion. Because you can easily read the book without thinking about slavery at all and much less American one. The word itself is used only few times.

Also, in born abilities are not the only way to become a slave in that book. Guardians are slaves too.
Lazarus 2.0 Released
Some people are still using the old analogy of Phone. When it has replaced your Camera, Internet Communicator, Gaming, etc.

Every single bit of tech inside the phone were more expensive, partly so because of rising wages in tech industry. Which I suppose most people on HN are benefiting from.
It's no longer about function. It's a component that happens to use `function` as an implementation detail.
they don't want to do serious curation

But their fees are commensurate with them doing that role.
Explanation for Existence of Adversarial Examples with Small Hamming Distance
Chicago IL Reverse Dementia and Memory Loss with Bredesen Protocol
> I've never seen any data that Canada has poorer gender equality or more age discrimination than the US.

Gender wage gap is much worse in Ontario than California (26% vs. 11%).

These are the two economic powerhouses of the respective countries. Hard to compare the nations on the whole since they differ in many other ways (Canada is a significantly more urban nation, for example).
I understand the point author of the question makes (which I suppose is "to recommend one book you liked" essentially), but if I would take it literally, as written, then - no single book ever changed the way I think about everything, or even about majority of things.
Of course, and I'm not arguing with that.

I'm arguing with the notion that science can't be used to figure out the truth. Even if it can't reach the truth in the mathematical/logical sense, it is still the best tool we have to move in the direction of truth.
Hooks offers nothing new over HoC and FaC the same way React offered nothing new over jQuery and EmberJS.
>Piss in a bottle

works for 50% of the population? I read a fascinating article recently (can't find it again I'm afraid) where a female UPS driver said her delivery targets were always lower than her male colleagues because she had to go and find a bathroom.
Theory of Transportation, Applied to Remote Controls, Cars, Bikes and MaaS
> 2. A relaxed interview, like above, in neutral ground like a coffee shop. I use the walk from office to coffee shop to handle company questios, and the standard interview stuff,

Perhaps that is relaxing to you and most people but not everyone. Coffee shops can be very distracting because you hear other people talking and walking by and some even play music. Perhaps you want to screen out such candidates anyway so it doesn't matter much. But you are also screening out a lot of skilled developers who don't function well in distracting environments.
I loved video games as a child and I said I wanted to make video games. In HS I took the only 2 Programming classes but somehow didn’t study it in college...? 4-5 years after graduating I started self learning with Codecademy and others. 4-5 years after that I took an online full stack boot camp with General Assembly and got a job 2 months later.

Of course throughout my life I’ve been very interested in tech, used Linux for many years, and was unknowingly practicing a lot of the foundational skills needed to be a good dev.
They controlled the camera? I can't find any statement indicating so.
I did something similar for a university project to show why input/output sanitization is so important. Very simple project (~100 lines iirc) but it did the job!

https://github.com/annnoo/websocket-chatxss

In my oppinion the most fun thing you can inject is the "Katamari"-Script:
http://kathack.com/
I think time will tell.

It's basically the magic vs explicit discussion all over again. Like usually in this discussion, the magic approach is really appealing until it doesn't work, and then the pro-explicit people will go all "told you so" on you.

I personally really prefer explicit, having cut my fingers on magic one time too often. Instead, I'll gladly create classes if the thing I'm making has its own state (of any kind).

In fact I pretty much disagree with the current trend of wanting to shoehorn everything into this idea of declarative and/or functional programming. Especially in a language like JS, functional programming and some cherry-picked ideas from OO mesh really well together. For example, if you allow me to drift a little, did you know that you can add methods to the prototype of an Immutable.Record? You can even use class syntax! More to the point, if there's one place where OO ideas shine, it's UI components. A lot of OO ideas were particularly designed and developed for UIs.

Just like "let" and "const" let me communicate to the reader whether a variable is going to change, I like how in React-land "class" and "function" let me communicate to the reader whether a component has mutable state. Hooks feels like a hack to be able to change the value of a "const" without turning it into a "let". Get over yourself, make it a "let" already.

So for me, Hooks is an attempt to throw the baby out with the bath water. I don't experience the problem it's trying to solve. I like classes when they're appropriate.

I get the argument that custom hooks allow for easier reuse than higher order components, but I think the difference is marginal; you have to wrap your mind around the exact same complexity. Plus I think higher order components themselves are overused, but that's another story.

But! The React people strike me as a rather reasonable bunch. I strongly doubt they're going to move React into a direction where you're forced to make your state (slightly more) implicit. There's too varied a community around React now. I think React with classes and React with hooks can perfectly coexist. Also if my favorite open source React tool adopts hooks and forces me to do the same here and there, then sure I might be grumpy for a few minutes but in the end, well, I'll survive.
>We've detected unusual activity from your computer network To continue, please click the box below to let us know you're not a robot.

Looks more like automated protection against scrapping, or perhaps DDoS-like access patterns. Bloomberg certainly could, and ought to, add an exception for Archive.org, but iI wouldn't read any nefarious intent to the current state of affairs.

On the other hand, Archive.is and similar work just fine [1], given that they download the website via your computer rather than via centralized servers.

[1] http://archive.fo/TkpaJ
Gresham College: Lenin and the Russian Revolution, lecture
might be a good start.
https://www.gresham.ac.uk/lectures-and-events/lenin-and-the-...
But if you were tasked with designing a vehicle, it would behoove you to know how the engine worked, rather than only using it as a black box.
You need fire to forge steel
>“Children will start to be introduced gradually to issues around mental health, well-being and happiness right from the start of primary school,” he added.

Why wouldn't adults just solve their mental problems instead of introducing them to children? Children have no problems with happiness or well-being. It's us who should learn from them.

big facepalm
I think the advantage of the van over an RV is that it can be nondescript enough that you can get away with parking in a much wider variety of places.
Analyzing the 2019 RSA Innovation Sandbox Finalists Funding
Anyone have any tips for people who have friends entering the van life? I just want to see one of my best friends be successful in this transition...
SEEKING WORK | London | Onsite/Remote | 3 month or shorter contracts or price work

Full-stack developer/team leader with 15+ years experience with web technologies, 10 years experience managing teams and 5 years experience running a business.

Capable of conceiving, building, deploying and maintaining entire applications from the ground up, as well as starting growing or managing teams.

Currently building an email marketing SaaS and looking for a short term contract, I can work based on a day rate or I could quote you for a piece of work.

Favoured tech stack: Rails, Postgres, Bootstrap, React, AWS, Puppet, Terraform

CV: https://hired.com/resumes/paul-odeon
> Children have no problems with happiness or well-being.

Have you ever met a child IRL?
Learning to Code Better with Lean Coding
Oh, this might be helpful. I tried optimising the linear typewriter (appeared on HN a couple of weeks back) using Z3 but it got nowhere useful even leaving it for a couple of hours to churn (contrast with simulated annealing which took 10 seconds per run and got good results >70% of runs).

(I suspect just because optimising 26! permutations is HARD.)
Apple is honestly the worst store experience for going in and just buying something. It's crazy.
I imagine that for complicated inputs, the solver will just "hang". Is this an issue in practice? Can you bound its runtime?
+1. even for "non-believers", there are practical gems that will benefit anyone who cares to really read it.
> Why wouldn't adults just solve their mental problems instead of introducing them to children?

Because people live in an artificial world. In the absence of real problems everything is emotionally traumatic, first world problems.

As I sit next to a war on a military deployment I await people to prove me right with the sadness of their downvotes.
ITT there seems to be a lot of sentiment that city/county local governments shouldn't be able to implement policy on anything but the most trivial matters. As if politicians and corporations residing in other cities are better suited to make impactful local policy. I dont get it...

Then again I am still scathing from a similar case study in my home town of San Diego, with Airbnb. Our city council passed some policies to regulate whole-home short term vacation rentals in residential areas. It limited whole-home short-term Airbnb/VRBO rentals to 6-months per year (you could still rent out a spare room or granny flat on Airbnb as much as you want).

Airbnb wasn't having it. They hired a gazillion signature gatherers to brute force a public ballot measure. I'm talking about a signature gathering army; they were such a presence/nuisance it led to absurdities like Trader Joe's filing a lawsuit against Airbnb [1].

To be clear, Airbnb is killing San Diego's local renter market. Over the last 5 years, thousands of rental properties have been converted to short-term Airbnb rentals. These images speak for themselves: https://imgur.com/a/UBJYbwr

This is on the heels of an independent consulting firm warning that sd housing and rental prices are rising at an alarming rate, and F grade in new housing development (blame SANDAG?), and single-family home prices slipping out of reach of median income earners (further saturating the apartment rental market) [2].

The natural reaction was SD locals filling town-hall meetings for several solid months, demanding city council take action (it was a sight to behold, because, I mean, when do you ever hear your friends say 'I just got back from a town hall meeting?'). And they did. And everyone cheered.

And then a week later it was all over.

The funny thing is; it won't even be a ballot measure. Airbnb understood that if they got the minimum number of signatures, they could force san diego city council to either (1) rescind the policies they just passed and start over on new policy more favorable to Airbnb - it had to be since laws require resubmissions after a petition to be substantially different; or (2) no policy whatsoever, until a formal ballot measure could be put in front of voters (i.e. 2+ years of no policy & airbnb propaganda).

TLDR; a silicon valley company has more sustained influence on san diego rental/housing policy than san diego elected officials

1. https://www.fastcompany.com/90231150/trader-joes-has-filed-a...

2. http://londonmoeder.com/wp-content/uploads/2018/06/Regional-...
The short story of how, if you're rowing a boat over a river and you hit another boat, you shout at the person in the boat how careless they are and why aren't they paying attention, and you're incensed and annoyed at their stupidity. Then you turn and look, and the other boat is empty and drifting, there isn't anyone in it.

I don't think I've ever stopped thinking about that story and how, even if there was someone in the other boat, I could react as if there wasn't, and things would be better.

Not a book, but once I'd read and re-read enough https://thelastpsychiatrist.com/ articles to start to understand his view on narcissism and how it's an epidemic problem in the West.

Something like https://thelastpsychiatrist.com/2013/09/how_does_the_shutdow... from 2013 about the government shutdown, or https://thelastpsychiatrist.com/2014/01/randi_zuckerberg.htm... from 2014 about why people are really so obsessed with Facebook and why we fill our home lives with work.
The HN crowd has always been hypocritical when bashing Uber but praising Lyft. They are the same kind of crooks.
Have it ever occurred to you that adults have mental problems because they didn't learn to manage it as children and young adults?

Besides, depression and anxiety is surprisingly common among children.
My daughters homework for each day this week is :

1. Talk about your feelings.

2. Do something you are good at.

3. Keep yourself hydrated.

4. Eat well.

5. Keep active in mind and body.

6. Take a break.

7. Stay connected to those you care about.

8. Ask for help.

9. Be proud of your very being.

10. Actively care for others.

She has a chart she needs to tick once she has achieved each item.

I get that they are all good things to do and perhaps it provides a talking point in families where these things aren't considered, but it seems a bit much to throw it all in at once. Next week she will probably be back to learning her 3 times tables..
Special interest groups generally can’t “fund his re-election” because it’s illegal for corporations to donate to candidates. It might be worth considering whether your belief that “it happens all the fucking time” is based on facts or some sort of inchoate narrative you’ve picked up over the years.
This is exciting, and at the same time I wish this came out before writing thousands of lines of code on my React app...

I can see the possibilities this brings, and they're much better than the mess of props, local state, redux, and HoCs that we have. But the refactoring needed is just insane.

Has anyone gone through something like this and has any tips?
open console. type this
setInterval(() => {$('.msg_send_btn').click()},50);
The way they function is completely different.

English: measure certain mass nouns or classify certain nouns. Not used for counting every noun.

Korean: Always used, regardless if they measure or clarify. Six dogs, three months, two papers, four volumes, one bowl, ten things all use counters. Always.

The difference is night and day.
FlatBuffers
You were a very lucky child then :)

Edit: Apologies for the sarcastic response, couldn't help it. Children can and do feel unhappy, some more than others. This feels like an amazing step in the right direction because many people (myself included) don't learn early on that feeling sad or overwhelmed is normal and ok. We strive to "feel good" and stress about it, without tools to cope. Most adults either ignore this or go to therapy, but maybe from now on people will be more prepared.
That depends - it's entirely possible to design and build vehicles using black box engines. What you might mean is "designing an optimal vechicle"? But for most people, they're basically working on simple CRUD stuff which doesn't need to be supra-optimal etc.

(I could make all my internal code supra-optimal, write all my own data structure code, handcraft some assembly, etc. but it would be beyond pointless since 99% of the time it takes to do stuff is in the database server.)
It wasn't against your lifestyle or even about van life or tiny houses, but more about the fact that what we perceive as "improved standards of living" have no logical foundations and aren't actually improving our lives.
I know that every NP problem can be written as an SMT problem, theoretically speaking. But is that actually practical?
I'm surprised that neither the article nor comments here to date point out that the original setting was the cartoon shorts series "Milton"[0], where Milton and Lumbergh are the central characters. The film's climax with Milton's breakdown is foreshadowed in the Milton series ("I could put strychnine in the guacamole...")

[0] https://en.wikipedia.org/wiki/Milton_(cartoon)

I think Gary Cole was underrated; he was awesome in "American Gothic".
Hooks seem to be a drastic change in how we're going to write React components in the future. I'm quite satisfied with the current way of writing components which is to me is very explicit (with no magic). With Hooks React is taking a different direction from their original motto of explicit design patterns. From the looks of it, Hooks seems like a counter-intuitive design pattern but traditionally that's how most of the JS concepts were before they went mainstream.

I'm going to wait and see for some production success stories become giving it serious thought.
>The initiative comes months after a survey commissioned by the National Health Service found that one in eight children in England between the ages of 5 and 19 suffered from at least one mental disorder at the time of their assessment in 2017.

>The survey, which was published in November, also indicated a slight increase in mental disorders in five to 15-year-olds, which rose to 11.2 percent in 2017 from 9.7 percent in 1999. Disorders like anxiety and depression were the most common, affecting one in 12 children and early adolescents in 2017, and appeared more often in girls.
In my experience kids, until a certain age, run around, scream, shout, full of excitement, happiness, and life.

But once they start looking at adults - all they see only dark, gloomy, lifeless serious faces and so they start becoming the same.

If adults want to do something about it - we should teach happiness ourselves first. Kids will follow automagically.
Isn't the term "Tech bro"?
My teenage brother just lost his father to cancer. But that's surely just a first-world problem.
The primary tip is: don't refactor. It's unlikely to solve any problems if you already have working code in which you've already dealt with all the hassles of HoCs and such. You can just start using it in new code to avoid having to deal with it for that.
What is the brand name/model of this thing? I'd imagine the fact that it survived being eaten and frozen would be a great endorsement for the durability of the product.
>Besides, depression and anxiety is surprisingly common among children.

Whom do you think they learned this from? Trees or cats?
Show HN: SnippetFu – store and copy to clipboard snippets of text quickly
Makers to follow: Popular founders with their startups, writings, and stories
SoK: “Plug and Pray” Today: Understanding USB Insecurity in Versions 1 Through C [pdf]
I've read a lot about hooks, the reasoning all makes sense but I'm still not fully getting it at an intuitive level. Like I get that it means you can write functional versions of class based components, an example of a complex class component that has been converted to a function with hooks would be good. The counter example really leaves a lot to the imagination.

The examples in https://usehooks.com/ aren't convincing me for some reason, but maybe that's just my lack of familiarity with the syntax so it feels more magic. Lifecycle methods like componentDidUpdate are super easy to reason about at first.
Making Chrome Extension with Webpack and Jest: source of YouTube Time Tracker
I don't think that children who have problems with happiness or well-being will be helped by teaching them mindfulness.

I was a lucky kid, but those around me who had problems had them because they were excluded from groups, got parents divorced, were bullied or were simply spoiled by their parents and were unhappy if anything didn't go their way. Telling them to be mindful is straight out of Voltaire's Candide.
The Mysterious Interstellar Object Oumuamua with Harvard's Dr. Avi Loeb
I disagree with some of that. But first thanks for explaining more in-depth what is behind pijul. The main subthread I started because I didn't understand what it provides. If it can combine easier UX with more efficient diffing, then I think it is a very valuable contribution, actually.

Now some more in-depth bla bla if interesting:

> (AB)C = A(BC)

great feature request, I agree.

> This isn't always what happens in git

correct.

> because it doesn't work with patches on an abstract level. Instead, it always works with states

Incorrect though. States, patches, these are just trade-offs. You can represent either in the other completely. Like you can build a list using a tree structure if you just allow one branch. Or you can also build a tree on top of a list structure, if your traversal algorithm knows which item-index to pick for a certain subtree's children. All trade-offs.

That doesn't mean "Pijul does better diffs" would be wrong, though. It can still be the case. But it doesn't mean that git would need huge refactoring to also implement that better-diff-algorithm. In the end implementing this better algorithm in git might be trivial for a git core developer if you can explain to him how it works.

If you think about it a diff between two states has an unlimited way of being represented. And considering minimal steps to generate the diffs with adding lines to the diff and removing lines from the diff, the whole thing is an abstract tree. Basically to achieve associative patches one needs to make sure to always traverse this tree in the same order. Git traverses greedily though, using the very first diff that is good enough as a final result. Probably the idea behind this was also smart. Do it quickly for now, and optimize it if needed later.
Even assuming depression must be "learned", what does it matter? School can't make sure they're never around depressed people. But it can help them protect themselves from it.
The point of the question is not books you like, or books which changed everything, but books which changed you.

If you grew up, as most people did, your world view was shaped by a child's world view seeing a small slice of local life and some nationwide lowest-common-denominator TV/media.

If you haven't read anything which has shaped, changed or distorted that brain you see the world with, you either had an unusual upbringing or you haven't read anything very interesting.