skysight-inc/HackerNews huggingface dataset:
Awesome. I just finished a small Mac App in Swift [1], and I've run into lots of small situations where I wasn't sure what the best practice would be. Really looking forward to reading this one.

In particular, I found the required casting of AnyObject! to whatever I was expecting it to be not perfect (sometimes I thought that the typechecker really ought to figure some types out). Also, best practices for when to use NSArray vs. Array / NSString vs. String, etc. is another thing I look forward to.

Also, Some of the issues I ran into are probably due to Swift being beta, so knowing what the right way should be (even though it doesn't work that way yet) is important as it keeps me from hanging on to bad style.

[1] https://github.com/terhechte/Swijito
Nick Kokonas of Alinea/Aviary summed up the threat to OpenTable in his recent post about his restaurant ticketing system[1]:

"At one time it was definitely the case that if I were looking for an Italian restaurant in a certain neighborhood I would consult OpenTable, read the reviews, and book directly. Now I just use Google or Google Maps. Google of course knows this and that’s why they bought Zagat. I’d bet Google will soon begin the reservations game as part of Zagat ratings."

Could Google deliver a reservation system to restaurants without renting them hardware and nixing the $14 customer charge? Sure. Could they even pay for the hardware out of their own pockets to get traction and dump a pile of Nexus tablets in every store? Absolutely.

Perhaps OpenTable management realizes this and figures this is a good time to exit.

[1] http://website.alinearestaurant.com/site/2014/06/tickets-for...
I think this is great, but it's really critical to understand the regulatory concessions Google won in this process (FTA):

> The agreement exempts Google from a 3 percent "PEG fee" that the city charges Comcast.

> Unlike Comcast, Google Fiber is not required to serve all parts of the city. Google says it will operate in "fiberhoods" where subscribers reach a critical mass.

So far Google has gotten these sorts of concessions in most if not all of the Google Fiber Cities, over public opposition: http://seattletimes.com/html/businesstechnology/2023420101_b.... Provisions like these are key barriers to establishing competition in other markets, especially for companies that don't have the negotiating clout of Google.

The media has tended to focus on the Google versus cable/telco fight, but at least as important if not more so is the precedent that Google's hardball tactics are setting for municipalities: if you want fiber, you have to give up these terms in franchise agreements. Google's efforts here will be a huge boon to companies like RCN that are attempting to build fiber in cities with established cable or telecom competitors.

There's also a third interesting point:

> Portland and Google will participate in a "joint defense" of the franchise if it faces a legal challenge over allegations it gave Google Fiber preferential treatment, exceeded the city's authority, or violates the law in some way.
Here is a great NYT piece on how civil forfeiture is abused in one Texas town:

http://www.newyorker.com/reporting/2013/08/12/130812fa_fact_...
Are these translation rules published somewhere? I'd really like to understand what keywords trigger what kind of mapping rules.
I've been impressed with our city council so far. Now let's hope they legitimize short-term rentals so we can continue offering Airbnb in Portland.
I think this is one of those things that people seem to "want", but has really been dictated to them by forces outside their control and outside of their immediate impact.

- Do people really "want" to drive 10/15 minutes to pick up the milk they forgot last time they went to the store?

- Do people really "want" to spend huge amounts of money on a car, insurance, gas.

- Do people really "want" to spend huge amounts of time in traffic on their way to and from work every day?

I could go on, but I think the answer is generally "no" to all those questions. And that's leaving out all the deleterious health effects we know commuting and the suburban lifestyle can cause.

What people really want is safe places, good schools, short commutes, good shopping/food choices, outdoor spaces, etc. We've been sold a bill of goods since Levittown on the "american dream" that offers the solution to all the problems of cities by creating an entirely different (and I'd say overall significantly greater) set of problems. It's treating the symptoms instead of the disease.
Great post, can't wait for beta!
For Paraskevidekatriaphobics Only
> That's the style in C-like languages.

That style is in many cases inefficient.

/* summation of successive integers */
/* don't worry, this should not cause overflow in a 32-bit signed integer type */
volatile int i=0;
int j=0;
for( ; i<65536; i++) /* ++i is better suited to this scenario */
j+=i;

Being declared as volatile, the compiler will not attempt to optimise the for loop and change the code that increments i in the preamble from postfix to prefix. I will admit this is an extreme example, but I often see examples on the internet of simple for loops written in this manner when prefix is more suitable and simpler for the cpu to execute. Postfix increments of integer types involve making a local copy (y) of the variable to increment (x), then incrementing x and returning y. Prefix increments merely involve incrementing x. The former method is rather expensive.

On the other hand, it would make sense to use postfix on something like [0].

[0] http://en.wikipedia.org/wiki/Duff's_device#Original_version
I'm sure there is a peak in there somewhere.

But 'older' and 'wealthier' does not equate to 'does not consume porn' or even 'consumes significantly less porn', at least, if the adult companies that I have stats about are anything to go by.

And that still side-steps the question of which age bracket spends the most money per-person on porn which further skews it.

The 50+ demographic is good for approximately 20% of all visits to porn sites and good for a dis-proportionally large percentage of the money spent.

So no, I don't think it turns off overnight after the birthday party.
Java/Python are (arguably) easier for writing complex standalone apps, and neither of those are platform agnostic. The problem isn't that JS is cross platform and other languages aren't.
On the backend maybe. Client side you're basically stuck with JavaScript and things that can be converted to JavaScript.
I have personally worked on a 7 man team on a 2.5m LOC codebase in Python (Python 2.4, to be precise). It wasn't public, though.

Working on the code base with dynamic typing wasn't _that_ hard. Certainly not as hard as people make it out to be.
No, Stanford gave that block back in 2000. See: http://arstechnica.com/information-technology/2014/06/with-t...

Microsoft has been purchasing blocks of IPv4 space (they bought some off of Nortel a few years back). Obviously they don't have enough.
This is the same as the online documentation that's been up since release: https://developer.apple.com/library/prerelease/ios/documenta...
The compelling use case for me was that I was already used to the Intellij key bindings, which tend to (mostly) remain constant across JetBrains products. It does use a fair amount of RAM, but these days 8GB seems fairly standard and seems to be plenty most of the time. I currently have PyCharm open and it's using 427MB.
They have to start somewhere.
Hello downvoter, please explain yourself.

http://www.mscs.dal.ca/~selinger/md5collision/
They actually do. It says "50% OFF for startups" on the pricing page: http://www.jetbrains.com/pycharm/buy/

More details here: https://www.jetbrains.com/estore/startup/
How did the phrase "non-US IPv4 address space" even acquire meaning? The purpose on an IP address is to name a system on the internet such that you can send packets to it. WTF does that have to do with geography? (Apart from the fact that you might generally want to aggregate geographically close systems into contiguous address ranges in order to keep routing tables managable, but that obviously has exactly zero to do with borders of countries and stuff like that, and more with the physics of signal propagation ...)
I think that given the fp imprecision of javascript, just storing either C or F is the wrong thing to do, and the "workaround" is actually correct.
Ideally, if you can convince a court there's a reasonable chance that the property was legally obtained (using income you legally earned), and that it wasn't purchased with the intent to primarily use it for illegal activities.

Proof beyond reasonable doubt doesn't mean you're definitely guilty. But if it seems reasonably likely (to the judge, or better the jury) that something was legitimately purchased for legitimate reasons, it should be yours.

Campervan fitted out as a mobile meth lab? That should get seized. The house your kid sold drugs from, but is your primary place of residence, and you paid for it with legally obtained money? That should be yours.

The problem is, US police forces seem to want to seize anything that's remotely connected with illegal activities, to raise revenue.
No, I actually am pretty bullish on bitcoin at the moment, though who can say what will really happen.
Native. I haven't worked on any mobile apps that are webapps for mobile, so I haven't used it with the JavaScript implementation.
This seems like it works on the same principle of the Monty Hall problem, where statistically you win more often by always throwing away your first choice - http://en.wikipedia.org/wiki/Monty_Hall_problem
I'm really glad that you're liking it! :)
> Those assets should be "destroyed" - just the way narcotics are destroyed when dealers get caught.

Why? You keep rephrasing the claim that what the government is doing is wrong and then say they ought to be destroying seized assets seized as instrumentalities or proceeds of crime the way they (generally) do seized items that are illegal-in-themselves like narcotics, but you actually don't make any argument for why this is the case.

Why should the government ever destroy property that is legal to own and possess and has value in the market? That seems to be a net loss to society anyway you slice it.
I actually wonder how hard would it be to compete with OpenTable. I know they won't target my country soon :)
> Please review the history of the various "East India" companies. I think you will find it an enlightening read.

I have, actually. What's interesting to me is that it really points out the inherent paradox, in that corporations (as we know them today anyway) actually owe their existence to the State. With the East India Company it was a Royal Charter.

Note that I'm just playing "Devil's Advocate" here to some extent. I'm not necessarily a fan of super-huge corporations with Nation-State level power. In fact, I'm not necessarily a fan of any entity having "Nation-State level power", including Nation-States! :-)
Restaurants are strongly tied into local culture. What works in one country may very well not work in another.
>> "In particular, I found the required casting of AnyObject! to whatever I was expecting it to be not perfect (sometimes I thought that the typechecker really ought to figure some types out). Also, best practices for when to use NSArray vs. Array / NSString vs. String, etc. is another thing I look forward to."

Same issues I was having. I was porting an obj-c class to Swift and continued to use obj-c objects (NSString etc.). I then had to put 'as NSString' at the end of most lines. I'm considering going back and experimenting to see where I can use swift native objects. Hopefully this book will shed more light on the subject.
Cocoa would be an awesome runtime for Flowhub! We already support bunch of other systems via a simple protocol[1], including C++ (Arduino and friends), C (GEGL), JavaScript (Node.js, browser), ...

http://noflojs.org/documentation/protocol/
Mike Mills Asks Kids of Silicon Valley Workers About the Future of Tech
I think the concerns are reasonable, but Google did give some different promises in exchange, including free internet for non-profits, free wifi networks in some areas, and their usual "free 5 megabits after install costs" access. The TV service will carry the local PEG channels.

I think trading short term franchise concessions for a few years makes sense. Later on I would require them to cover all households in general areas they operate in, for example.

I am cautiously optimistic.
Can Synthetic Biology Survive in a World Haunted by “Frankenfood”?
even if he is just trying to recoup unpaid wages? there are fairly strict laws in this country surrounding that. I understand how being in litigation with a previous employer would look bad to a potential new one but I'd like to believe there is at least a little leeway there.
I was eager to learn about HTML5 Canvas, so I created a small project and learned a great deal while developing a lightweight canvas library, which hopefully others will also find helpful. https://github.com/vladakilov/imagine
I would suggest CloudFlare: https://www.cloudflare.com/plans

Their free plan offers lightning fast DNS (fastest I've ever seen) as well as a CDN. Love these guys!
well its neat they could be some basis for it. Granted they would never have known about this but if there were a chance the water could break surface, catastrophic earth quake or some such fun never experienced since that allowed this water to reach the surface, just imagine the outcome. After all you would not have water falling from the sky, it would just be there all around you.
I'm pretty sure that's just a misstatement in the documentation. The Swift code is equivalent to the UIColor initialiser, there's no need to auto-translate the factory method as well.

The auto-translation process for initialisers is described immediately before the part you quote.
It would have been useful if it had "English words starting with" and "English words ending with". Or a simple way of filtering sets and using them as subsets.
The pool is way lower:

- Girls in your range (age, available, and close geographically)

- Average time you need to 'learn' a girl (it is, to know the best/cons, and to take a decision if dropping her or not). On some it will take 2 hours, others will take 6 months or even years in some cases.

- Time when you start dating.

- Time when you plan to marry.

- Average time between dates.

So if living in a city big enough, and you start dating at around 18 and plan to marry at around 30, while being skillful enough to get a new date in less than 2 months, you can expect to date around 24 girls. That means you can discard the first 9 dates, and wait until you are almost 22 (3.75 years later) to take things seriously.
I stand corrected :) both about fungibility and about the trading volume.
Yeah, ASmallOrange is another one I forgot about. Thanks!
This book was sufficiently depressing to turn me off to disaster weather news forever. Nightmarish even.
You're right, I stand corrected :) .
> Maybe companies / corporations with enough power to actually challenge the governments of the world isn't such a bad thing after all.

Corporations are entities who owe their existence to government and can be terminated at a whim by government. If the government chartering a corporation decides it shouldn't continue to exist, it doesn't exist anymore.

This gets obscured a lot by the fact that the same class of people that derive the most benefit from the existence of corporations also have disproportionate power over government, so that this power is very rarely exercised, but that's not because corporations are powerful enough to resist government or even theoretically could be, its because corporations and governments ultimately are run by the same people.
It would be more accurate to say that direct participation was not scalable past a certain population size.

But now, well... Nintendo even made a free Wii amusement called "Everybody Votes Channel". If people are willing to waste time voting on silly things just to see what other people in their tribe and around the world selected, they can certainly vote on things that actually matter to them, like taxes and laws.

The difficult problem nowadays is not the technical ability to get everyone participating, but how to avoid the pitfalls of democracy, such as an arbitrary majority tyrannizing an arbitrary minority, or a focused minority advancing a specific agenda over a relatively apathetic majority.

There would almost have to be a submission petition with a certain number of supporters, an initial 50% majority of those who care to vote to trigger spending development resources on the issue, then a funding round, where supporters have to supply the required budget directly, and finally a ratification round, where a supermajority, perhaps 67% of all possible voters, where non-voters automatically vote to reject, determines whether to proceed to implementation or not.

But that's all irrelevant detail when it is likely that those who currently hold power would use it to prevent a new system from taking it away from them. The status quo likes where it stands now. The system is ripe for disruption, but it is also quite good at retaliating against existential threats.
Although MD5 has known collision issues, using an MD5 collision to alter the text of the document in a specific manner is highly unlikely. This is not as trivial as simply generating some random bits of data that result in the same signature when hashed.

In the use case where you want to change the document for your own purposes without leaving evidence that you've tampered with it, you would not be searching for just a single other file which generates the same hash value. You would be looking for another file which results in the same value when hashed, has the same format (text is easy, I suppose, but it's conceivable they could switch to a binary format at some point), makes grammatical and syntactical sense, and also contains the desired content that you are looking for (or some approximate.. the 'exact' desired content would result in a different hash in most scenarios).

That said, I agree that there are better hashing algorithms out there. Multiple signatures from several common hash functions could be provided for quick confirmation purposes while still making it relatively easy to validate quickly.

(Edit: Also, since you are concerned: I am not the downvoter)
OpenTable isn't just a reservation system, it's a full-on restaurant management system. They've seen this possibility coming and they're reasonably well positioned to deal with it.

OpenTable only does reservations when facing the diner, but when facing the restaurant they do reservations, CRM, payments, table tracking, and analytics.

Whoever wants to replace OpenTable needs to replace all of this at once. Not only that, they need to convince a restaurant to ditch practically their entire IT stack, retrain all of their employees in the new system, and do so without service or quality interruption.

OpenTable has positioned themselves to be about as sticky as you can imagine a software business to be. They've locked in their vendors hard. Evil? Probably. Very effective? Hell yeah.

It's not as if no one's challenged OpenTable before - there are in fact a number of restaurant management startups out there, but none can even dent OpenTable's dominance due to the lock-in. Google couldn't take out OpenTable even if they tried, not without burning a pile of cash taller than this current purchase price.
Cheeseburgers in Paradise?
The same principle applies to brakes in heavy goods vehicles.
Well this is rather upsetting, it seems extensions still cannot add stored properties... Back to using objc_setassociatedobject and objc_getassociatedobject it seems for extension properties, sadface.

Also seems you can't override existing methods or properties still (actually achievable with swizzling of methods & property getter/setters on init but always seems way to heavy to use in reality). I would love to have a more mix-in friendly environment at some point in time.

“You can use extensions to add properties (including class and static properties). However, these properties must be computed; extensions can’t add stored properties to classes, structures, or enumerations.”

“You cannot use extensions to override existing methods or properties on Objective-C types.”

Excerpt From: Apple Inc. “Using Swift with Cocoa and Objective-C.” iBooks.
Governments always expect to be tracked, the only surprising thing is when voters see the results and pay attention.
Yes, Google is offering free internet after a $300 up-front payment, in neighborhoods that otherwise justify fiber deployment. In contrast, for example, cable companies are generally required to offer basic service everywhere in the franchise area for $15-20 per month. Given that most of the cost of deployment is building to the neighborhood, and that neighborhoods are economically segregated in most cities, the former concession is much less onerous than the latter.

Again, I don't think fiber should be beholden to universal access. I'm just pointing out Google has won a major political battle here that has major precedential value.
SolScript looks fantastic.

Considering Avionics domain, using Coq or ATS to prove the correctness of SolScript compiler will help boost confidence.
Watch The Daily Show Destroy Google Glass And Glass Explorers
Yes, that's what I was referring to. Instead of "money," perhaps I ought to have said "value." Analogously, if I had a pound of gold, and I gave it to a broker to sell for me, I'd be trusting that broker with my "value."
Does not work properly, many domains listed as available, when they're actually not. Would have been useful if it worked properly.
Well, there are free and almost free satelite photos of the entire Amazon jungle available. Thus, nothing is stopping you.
Yes and open table is already doing it. They reward repeat customers who pay full price (their point system) not try to generate new customers who are a poor fit for long term business by discounting their meals.

Discounts are for getting rid of excess merchandise, not acquiring new customers.
Why Swift is Better
No, because you can go back to a better idea anytime you want to do so. If you estimated that you have 12 months of savings and that it takes you a month to build an MVP and six months to take an MVP to ramen profit, you should spend the first six months building six MVPs, then evaluate them and pick the best to work on for another six months.
I was thinking exactly the same thing reading the headline.

Good design will give you a lot cleaner professional maintainable code.

I do databases, but I like Linus's quite about getting the data structures right, and not needing to worry about the code. I find if the application level is getting too complex, it probably means the database design isn't matching the problem correctly. Others on my team would keep adding "if" statements to the forming ball of mud. (Usually) I find it easier to take the pain of a schema migration up front. The code then becomes simpler, more reliable, and I can usually forget about it.

As for the text editor comment. In general no, but I know a lot of poor programmers who are too lazy to set up / learn an IDE (or any other way of using a step through debugger).
So you are saying that the audience for the blog post consists of an overwhelming number of people that understand that meme? As opposed to people who do not? I disagree.