skysight-inc/HackerNews huggingface dataset:
Ask HN: JS's for-of loop conceptually flawed, or is it just me?
When working with generators, two identical for-of loops don't show the same behaviour.
Specifically, the first one will behave as expected, whereas the second one will terminate immediately.
What is this?

I know that the iterator `g` will signal the value `done` after the first loop, but this behaviour was unexpected and really counterintuitive to me

Note: contrary to this example, for-of loops of arrays will work as I expected. It just doesn't make sense

Code example:

> function* gen() { yield* [1,2,3] }

undefined

> let g = gen()

undefined

> for (let el of g) console.log(el)

1

2

3

undefined

> for (let el of g) console.log(el)

undefined

edit: layout
> competition is a stronger emotion than community.

yep i guess this is a rule: as population increase, humanity decrease

that is why is really cool to live in small towns
This is an early release for OSX, you should add that to the title.
Ok now that I've read all the problems that could cause https://bugzilla.mozilla.org/showdependencytree.cgi?id=e10s-... , I feel bad about recommending it.
Transmitting deauth packets is illegal according to cases involving hotels and conference centers jamming wifi hotspots.

https://en.wikipedia.org/wiki/Wi-Fi_deauthentication_attack
(1) I'd advise you to push out the sales guys -- they don't seem to be pulling their weight. Feel free to give them 5% each for their work, whatever seems reasonable, but not more than 15% total.

A startup is kind of like a marriage. If you don't trust your partner when you're dating, you're not going to trust them when you get married.

You can do sales and product development too. It's a skill that can be acquired.

(2) You'd better talk to a lawyer.

Keep in mind Thiel's law: a startup screwed up at it's foundation cannot be fixed. You should use your muscle to make this right now, or it's all going to fall apart sooner or later.

http://blakemasters.com/post/21742864570/peter-thiels-cs183-...
I mean, I really try to avoid being snarky, but a basic google search.... https://tails.boum.org/

It gained some additional fame because Snowden used it: https://en.wikipedia.org/wiki/Tails_(operating_system)#Histo...
So anytime the designer makes a change to the structure of the application, where HTML element changes are required, do they send you a request so you can change it?

It seems odd to only allow the "designer" to manipulate properties of elements and not the elements themselves. If they are allowed to modify DOM elements then in the React world, that is manipulating JS. For us the important separation is at the component level, which includes everything that component needs to render and function (HTML, CSS, JS).
Even the door on Google’s self-driving car has its own patent
To be fair, both devdraw GUIs have a long-standing improper scrolling issue, which may or may not be a feature because it's simple and fast.
It definitely will affect GALILEO, the US threatened to embargo the EU if GALILEO would be impossible* to jam.

(Well, "impossible" – the original EU plan was to reuse the same frequencies the US and Russia use for military GPS and GLONASS for GALILEO’s civilian use, but the US threatened some embargo, and so GALILEO isn’t the awesome thing it could have been)
> If you are a master painter, you could paint something amazing with anything you have got. Same thing applies to programmers.

That's a flawed analogy. Here is a better one:

If you need to drill something, do you consider a screwdriver and an electric drill equally?
A Solar Powered “Forever Drone” May Be Replacing Our Satellites
Show HN: Docshare.io – Instant Document Tracking and Notifications
I've been writing Go daily for almost two years now and outside of wishing for generics a few times I've never struggled to fit a solution into the type system. I've certainly never considered going back to a duck typed language like Python or Ruby. Not once. Not ever. We have slowly replaced even our glue scripts that are written in Python with Go versions because maintenance and understandability trump any perceived speed advantage of writing something in Python.
"All the capital you raise?" They've raised 190K.

Uber has raised 12.5 Billion dollars.
That was the trend for some time. Unfortunately, I've known some that lost a house due to lack of being able to sell it for the loan amount and known others that just barely broke even (they might have had to pay fees out of pocket).

My aunt and grandmother made money on a condo some years back - but that was before the bubble burst.
Google, Apple, Amazon Fight Over Artificial Intelligence
There are two ways to get rid of them:

I am already a member, customer, etc

Just ignore them. Don't change you walking speed, don't acknowledge them, don't argue them.
Cool library, any thoughts on https://github.com/rtsao/csjs

I found it to be a great middleman between CSS and JS, with full CSS support.
Amazing! So nice... When I saw github page, and that Swift yellow color in language details line, smirk was drawn on my face! <3 Native desktop apps
It's 9 vertical pixels, actually. Standard CGA font was 8x8, using the last column for character spacing, and the last row for descenders:

http://www.seasip.info/VintagePC/Images/cga.png

So then you need one more row to separate lines (or live with the occasional joined characters, as CGA did with its 640x200 resolution).
Yep, but those languages also define equality in their type systems using the package paths. It's tricky, of course. :)

We want to be able to track function moves and renames across packages or even repositories. It'll take some more work to get there.
Blizzard Will Allow Users to Stream Its Games via Facebook Live
I'd go nuts with such long launch times, regardless of daemon mode.
Facebook-like content placeholder
Oh yeah! I've been waiting for over a year for this HN username to pay dividends!
How Windows 10 became malware
132 was too long given the resolution of displays at a time. I don't think it necessarily says anything about the easiness of parsing a string that long per se.
4x drop in battery prices, (or) 5x increase in density in only 8 years. Pretty damn good for batteries that "aren't following Moore's Law", something most battery-related articles are quick to remind us. Hopefully, this continues for at least another decade, which should make EVs more than competitive with ICE cars.
The difference is that Apple doesn't actively try to prevent Homebrew from working, while Microsoft has issued updates with the purpose to rename NT services and other things, in order to defeat the workarounds.
I thought this was an official app for a moment. Saw this:

"The app has a powerful search feature. When you first launch the app, It indexes the videos database and downloads transcripts from ASCIIWWDC, so when you search, not only will you get search results from session titles and descriptions, but also from what the presenter said in the sessions."

And was all pissed off.

"Damnit, Apple, how about you do something similar for the App Store?!?"

Then I realized...
Even if your home never appreciates... one day when you are too old to work you will really appreciate a place to live that you only have to pay property taxes on.

However there are reasons not to own a house like wanting to be very mobile, not wanting the responsibility, wanting to live in more of a "group" environment, etc. If you live on the edge and can't save money then you shouldn't own a house because if you loose your job you won't be able to continue making the payments.
I've allegedly been involved in operating some of the largest *nix botnets ever, and certainly haven't seen anyone do that.

Scanning every single port on /0 simply takes way too much time even with millions of nodes, you're much better off improving your coverage over the common ports and catching new (and old) equipment coming online.

Of course, this wouldn't necessarily be true with the "preauth opensshd 0day" brought up in TFA. Such an exploit would certainly give you more than enough BW to do whatever you want, and break the internet while doing it.
Parent's claim:

Of course, but not all tools are equal. In programming
languages, languages that have a static type system have
an insurmountable advantage of dynamically typed ones.

Your response:

javascript and python would disagree with you.

My question:

How so?

Since the claim is about the advantages of static type systems, I'll respond on that claim alone. The primary advantage of static type systems, particularly expressive ones, but even of less expressive ones like C, is that a large class of errors can never occur in run-time code. You cannot, possibly, without deliberate effort to defeat the type checker do the following in a statically typed language without at least a compile time warning (to permit C and its weak type system and occasional implicit casting):

Define a function in your language of type: int -> int -> int [or (int, int) -> int]. Pass in something that is not an int to either parameter.

Python will happily accept this code:

def add(a,b):
a + b
... some context
add("aoeu", 3)

And not tell you until that add call occurs. A run-time error. Could be very infrequent, which makes it really hard to reproduce.

In C:

int add(int a, int b) {
return a+b;
}
... some context
add("aoeu",3);

the add call won't even make it past the compiler.

JavaScript is even worse: You won't get an error at all!

function add(a,b) { return a + b; }
... some context
add("aoeu",3) // results in "aoeu3" as the return!

Dynamic and weak typing!

This doesn't mean python and javascript are bad. But it does mean they possess disadvantages relative to statically typed languages. Their type systems mean that significant testing has to be put in to verify/validate your program for guarantees that are baked into statically typed languages (caveat for implicit conversions of certain types, again, in languages like C, but this usually gets at least a warning if not an error).
I think a better approach to a strong security and privacy would be to use Whonix[0] in Qubes[1].

It's not too hard[2].

0: https://www.whonix.org
1: https://www.qubes-os.org
2: https://www.qubes-os.org/doc/whonix/install
My university required us to change passwords every semester, and the password couldn't contain a similar enough substring of any of your old passwords. (I think 4 characters was the threshold, it would also detect reversed substrings).

I didn't really know much about web dev or security at the time, but thinking back to it now, there is no safe way they could have done that.
I am just starting to look into these corpuses of pretrained neural networks. Coes anyone know if there are any image corpora with pretrained wieghts that would be suitable for analysis of "high-resolution" images derived from LIDAR data (where in this case high resolution corresponds to a resolution limit of a few meters). In the not unlikely case that there is nothing so specific, can anyone comment on the same for optical satellite imagery?
Apparently I'm supposed to believe

"Perhaps syntax highlighting was invented to speed up the reading process.
...
Well, no. One of the basic rules of thumb in typography is that, when writing a piece of text, you should choose one typeface and stick to it"

and then believe the rest of the article. Well, I don't believe that part, since I experience the complete opposite every day. A silly typographical guideline doesn't affect my experience at all.
Between this and the projected increase in PV solar efficiency, drop in cost and toxicity of manufacture... I don't think I've felt this kind of cautious optimism for a renewable energy infrastructure before.
This title needs to change because it completely misrepresents the original article.

And it's wrong, too. "Never pays off" is simply stupid. My parents bought their house for $250k and sold it 20 years later for $1.4M cash. To say it didn't pay off is simply ridiculous. My own house is worth 50% more in 3 years, obviously unsustainable, but nonetheless worthwhile, especially given rents.
Ah! You're right, I didn't think that through. iptables is indeed a safe way to do this, however changing your port in the configs to a highport isn't.
Snapchat's Redesign Aimed at Attracting More Eyeballs for Publishers and Brands
I think he means don't buy a house at the wrong time.. which is now because the gov't continues to over subsidize housing post crisis because america is a consumer economy and consumers only consume when they feel rich. How do you make a homeowner feel rich? Tell him that his house has doubled in value - sweet HELOC city - what could go wrong? (AGAIN) - Everyone and there mom should watch Jim Grant's speech at Google, the Keynsians are running a crazy world.
You reached the end of the iterator with the first loop, so there aren't any elements left in it to iterate over. That's consistent to how iterators work in other languages at least.
sounds like this is really prejudiced against poor people. Why is a poor neighborhood inherently more stressful than a rich neighborhood? What's the root cause? Not enough XBox's per capita?
Desalination Breakthrough: Saving the Sea from Salt
And my anecdotal experience is losing ~100K selling a house in the down market of 2009.

As for whether a condo makes its money back - suppose someone doesn't plan to sell it? A place to live is more than a profit/loss or investment decision. As the article mentions at the end.
Semantics are more important than syntax, sure. But it doesn't matter what the semantics are if you screw up the syntax, which you will be more likely to do without syntax highlighting because you're a hairless ape.

I just don't see an actual reason not to use it, but if you don't want to, knock yourself out I guess.
> in the latter cases we were trying to explain something external that we thought we were observing, whereas with subjective experience we are discussing a phenomenon that we (or at least some of us) directly, infallibly observe.

There's no distinction. When I see what looks like a broken pencil sitting in a glass of water, I am observing exactly what I describe. The reason the pencil looks broken is not because I should grant water some magical powers to break and reconstitute pencils, but turned out to be refracted light.

Analogously, I can observe that I do have subjective experience, but why should I assume that the reason I have subjective experience is different than all other observables? Why would it be some irreducible, unobservable quality?

You seem to be claiming that the existence of subjective experience is reason enough alone, and I don't see how that follows.
> I tried bringing up the fact that prices and things simply cannot always go up in value

My observation is that house values usually don't go down. Since people refuse to sell at a lose. But values can go up really slowly. Like it may take years and years.
“Audiograph” – Buildig a WebGL/WebAudio Visualizer
Non-constitutional exceptions to the constitution are just like Darth Vader: "I am altering the deal. Pray I don't alter it any further."
No Room for Old Technology in New Airport Towers
Great concept. Tempting, but the digital version I set up saves a bit of drudgework with the pen and could be a little more private. [0]

I like the bullet signifiers. I split events and tasks into calendar and todo list, but the bullets could work in a long, timestamped single file. Perhaps using # to comment out lines that are complete. Might make more sense than the archiving I do by moving to the bottom of the todo list. Actually, my calendar events comment out the done lines, so perhaps the todo really should too. Anyway, good share.

[0] https://github.com/luxpir/plaintext-productivity
It least it doesn't seem functional, so it looks like it can indeed be defended as a design patent in court.

To be completely nonfunctional it shouldn't have a handle though. :-)
Obviously "never" is false. As with every type of investment it "sometimes" pays off.

I think the point of the article is just that it won't ALWAYS pay off (especially at a 10% growth per year thing). This should be common sense but maybe isn't. Lots of things should factor into a purchase decision. If timed right, a home can very much be a good investment, but is absolutely not without risk.
Because having Project installed is an early step in being forced to use Project.
Dodgers and Dips – The Dark History of the Dunk Tank
>Well, no. One of the basic rules of thumb in typography is that, when writing a piece of text, you should choose one typeface and stick to it. Likewise, a splash of colour may grab the reader's attention, but it will inevitably decrease the legibility of the text. The natural flow of the text is broken, and it takes more brain effort to piece together the individual letters into words and semantics. Cognitively, the reading process becomes slightly less automatic and slightly more conscious; leaving less room in the conscious part of the mind for actually understanding the text.

That might be true for text, but I don't read code at all the way I read prose. I highly doubt i've ever read more then four or five lines of code in a row without my eye jumping to other parts of the function, forward to the next part to understand why variables are being set up, or backwards to remember when such variable was defined, or jumping to the big picture to remember how this function or that fits into the overall program. Syntax highlighting is enormously helpful to my eye when reading in that manner.
There's no winning with some of them. If you select 4 stars or higher "Great, please continue to the app store and review us!". If you answer with 3 or fewer, "Oh no! Please visit our contact page and tell us how we can make it better!"
here https://www.youtube.com/watch?v=KAWxhdPGJfU
> It's easy to spot all the verbs, but why on Earth would you want to do that?

The big difference between genuine reading and coding is the variability of scanning / focus. When you read, you usually want to take it all in -- it wouldn't make sense to jump around because it's a single, linear journey.

Code does not observe this rule, so the more experience you get as a coder, the better scanner you become. You quickly view a class and think "ah yes yes.. it's _roughly_ doing this.. that" -- you sure as heck don't read the whole thing carefully word by word! The best coders are amazing scanners -- capable of pointing out a missing parenthesis in a sea of parenthesis. This argument against syntax highlighting is like taking the batteries outta our flashlight. Sure, we'd be more careful but our productivity would surely suffer.
I'll keep it, thanks. My life is far easier with it. You are welcome to use Notepad.
Honestly, I don't worry about that at all.

I had a machine compromised in 2001 by script kiddies and worms scanning the internet on port 22 and compromising any host they could find with CVE-2001-0144. Not by attackers hijacking TCP connections.

In 2016 I am worried about a 0day being released and scripts kiddies or a worm compromising every host they can find running sshd. This effectively happened to debian systems in 2008. I don't know how you can say that it doesn't make sense when it happened.
I have observed exactly this in team group chats at work, where addressing the group results in being ignored, but didn't make the link until you brought up that car accident example.
Its almost like we're going to fix the climate change issue, slowly (ramping up quickly)....by sheer luck of technological advancement.
But how does that work if this translates everything to traditional CSS?
In fact if we end up patrolling Muslim neighborhoods as some presidential candidates have suggested, I suspect we'll only end up increasing terrorism.
One of the most horrifying things I ever read was the first(second?) chapter of A Brave New World. The thought of not helping a person is bad. Fysically stunting someones growth makes me sick. To just do it to escape the ethical debate at a later point is horrifying.
This is true but keep in mind that you have to set up a pipeline for collecting the data into HDFS (Storm? batch loading?) & you have to pay for the machines.

So while your analysis is valid, there are more "costs" at play like developer time, cluster maintenance, hardware. I like to play with Spark's ML libraries but am wary about designing projects specifically around them because of this overhead, especially when trying to distribute some API/tech that you'd like others to use.

Not trying to be a downer, I actually wish the choice to go distributed was more of a no-brainer, hah. Would love for some APIs to emerge that could be used locally/distributed transparently without actually having to run a dummy cluster & data migration to run locally.
Serving malware via physical legal documents
IMO switching an enterprise developer from language such as Java to Go is like asking someone who has very developed vocabulary in English to try Toki Pona[1].

Yes, it is simple, and you can learn it fast, you also can also communicate with it, but you will often have to fight with the language to express what you want. That person generally won't be satisfied.

Go's shortcomings wouldn't be so bad if in exchange, the language would ensure that your code is less prone to errors, but that doesn't seem to be true. In fact Go programs from my experience appear to be slightly below average in terms of stability and robustness compared to other statically typed languages.

[1] https://en.wikipedia.org/wiki/Toki_Pona
Can't tell if this comment is sarcastic or not
Cleaning is very sophisticated and complicated work. We observed even small detail can change customers' satisfaction. Current robot technology is still very early to handle complex human work like cleaning.
In a longterm, robotic tech is opportunity rather than threats. Though we do not have specific plan to make autonomous cleaning system, we can take advantage from robot innovation.
I have long offered the following advice.

If you have code that is not able to run any more in a scripting language, and it is not embarrassingly parallel, you have two choices.

1. Move to something like C++, and optimize the heck out of it. You will gain something like 1-2 orders of magnitude in performance and then hit a wall.

2. Move to a distributed architecture. You immediately lose 1-2 orders of magnitude in performance, but then can scale essentially forever.

If you expect your distributed system to need less than 100 machines, you should seriously consider option #1.
It goes both ways. If you break in the middle of the line just because you need to follow the standard, you may end up breaking in the middle of a construct that is really meant to be read as a whole; and having to move your focus to from the end of one line to the beginning of another is quite disruptive to the flow.

I'm also not convinced that 80 chars "happens to line up quite well with the human eyes ability to track horizontal lines of text". It's claimed often, but in the absence of any actual studies, the best you can really say on this is that it is your subjective experience. Mine is different - I find 100-120 columns per line to be eminently more readable.

Until the aforementioned study determines what the average peak readability length of _code_ (which I think is likely to be different from regular text, because the semantic units are different between the two), we'll just have to agree to disagree.
It depends on the area. In San Francisco or Boston, buying a condo is fine. In other areas, buying a condo may be a bad idea.
Federal judges are not elected
> I can conceive of no way to logically deduce its occurrence from any physical processes, nor any way to consider them as the same thing.

That you cannot conceive of it does not make it inconceivable. In fact, scientific theories [1] exist to explain exactly the functional purpose of consciousness.

[1] http://journal.frontiersin.org/article/10.3389/fpsyg.2015.00...