HNHacker News
TopNewBestAskShowJobs

program

992 karma · joined October 22, 2010

submissionscomments
program··on Epileptic seizures can be predicted through researchers' software
> Gras and Golestanti have patented the software, and now need a device that can constantly monitor a patient’s EEG.

As far as I know there are no portable devices that can produce a clean EEG. Motiv/Neurosky devices don't count.

Addendum: in the USA you can't drive a car during the 365 days following the last seizure

program··on Amazon.com redesign
PageSpeed 47/100 desktop, 51/100 mobile

https://developers.google.com/speed/pagespeed/insights/?url=...

program··on Gnome developer creates new animated image format
Safari 8 has no problems with "image/svg+xml". It renders the "image" if you open the link: http://funny.computer/cloud/XNG/distance.xng

For getting the xng on the page just replace the <img> with an <embed>.

program··on Pebilepsy – Pebble app for seizure tracking and measurement
Great device to be used during the sleep.

As an epileptic I doubt that this kind of device "can help them (the epileptics) adjust their medications." My neurologist adjust my medications every 6 months after studying my blood analyses, standard EEG and sleep EEG.

program··on Dimensions – Measure everything you see in the browser
The very interesting thing is that it goes through transparent portions of png backgrounds. Try it in the google logo.

I am very impressed.

program··on Highcharts – JavaScript charting framework
According to the site the 90$ price apply when:

"For use on a simple webpage that is not considered a web application. A web application is a website that has customer specific data or charges for its use. This requires a Developer license."

http://shop.highsoft.com/highcharts/highcharts-single-websit...

program··on Videos about JavaScript
Addendum: WAT, it's very funny

https://www.destroyallsoftware.com/talks/wat

program··on Atom: Hello Windows
The joke: a past Microsoft keynote by Steve Ballmer.

https://www.youtube.com/watch?v=Vhh_GeBPOhs

program··on Ask HN: Have you read "The Art of Computer Programming"?
"It's a pleasure to meet you, Professor Knuth, I've read all of your books." (Steve Jobs)

"You're full of shit," (Don Knuth) [1]

I think that no one in the world, except Knuth, has read the entire TAOCP (joke.)

[1] http://www.folklore.org/StoryView.py?story=Close_Encounters_...

program··on Interesting Swift Features
Operator overloading can potentially be abused because in Swift you are not limited to standard operators like in C++.

https://developer.apple.com/library/prerelease/ios/documenta...

According to the documentation you can declare an operator composed by an arbitrary list of this characters "/ = - + * % < > ! & | ^ . ~". You can recreate C++ stream operators (<<, >>), Ruby combined comparison (<=>), and so on.

program··on 2048 is why we can’t have nice things
I've played both games. The only difference I see (in term of game mechanics) is that 2048 have no "3" tiles but only power-of-2.
program··on JavaScript Equality Table
If you write ([[]] == false) you compare values of this object. Internally a [[]].toString() is called which gives an empty string (cause the first element is also an empty array) which in turn is considered false in javascript.

Otherwise [[],[]] is true cause cause [[],[]].toString() gives you this string: ",".

program··on Ask HN: What's the largest website hosted on Digital Ocean?
I don't think that such list could contain websites under reverse proxies.
program··on Ask HN: What's the largest website hosted on Digital Ocean?
jsFiddle is the biggest according to myip.ms

http://myip.ms/view/web_hosting/38903/Digital_Ocean_Inc.html

program··on CSShake: Some CSS Classes to shake your DOM
In fact Wordpress shake the form on /wp-admin/ if the login failed.
program··on Objective-C isn't what you think it is
On revision 2.0 and later Apple has included a lot of modern stuff like: ARC, properties, literals, blocks, fast enumeration, etc.
program··on How does Facebook disable Developer Tools?
OS X is an Open Brand UNIX 03 Registered Product since Leopard and given this it can be considered "complete." It isn't shipped with a compiler but your can install the cmdline tools (without all the XCode bundle) typing:

   xcode-select --install
on (Mavericks) Terminal.
program··on Chrome Bugs Allow Sites to Listen to Your Private Conversations
As a side note: is it a good thing that a window obtained through a Window.open() inherits the parent window's permissions?

Right now in Chrome permissions are enabled or disabled globally with exceptions based on hostname patterns. Adding a new option like "Allow popup window to inherit permissions" will solve the issue.

A well-hidden popup window can track your position all day using the geolocation API?

program··on Chrome Bugs Allow Sites to Listen to Your Private Conversations
Let's read the spec: https://dvcs.w3.org/hg/speech-api/raw-file/tip/speechapi.htm...

"To minimize the chance of users unwittingly allowing web pages to record speech without their knowledge, implementations must abort an active speech input session if the web page lost input focus to another window or to another tab within the same user agent."

Given this the actual Chrome implementation is wrong.

program··on Structuring Modern Objective-C
Enable modules and use them to import system frameworks:

   // #import <Cocoa/Cocoa.h>
   @import Cocoa;
Use literals and subscripting methods:

   NSNumber *yes = @YES;
   NSNumber *number = @42;
   NSArray *array = @[@"Hello", @"World"];
   NSDictionary *dictionary = @{ @"name" : NSUserName() };
Learn about "instancetype": http://clang.llvm.org/docs/LanguageExtensions.html#objective...

Always use NS_ENUM and NS_OPTIONS to declare enum types:

   typedef NS_ENUM(NSInteger, HNExample) {
      HNExampleDefault,
      HNExample1,
      HNExample2
   };
program··on What is your best programmer joke?
This article from devhumor: http://devhumor.com/193/

The assembly panel is very funny.

program··on An Illustrated History of objc_msgSend
In my opinion the confusing part is not about SEGFAULT or NullPointerException. Let's make and example:

   NSArray *obj = nil;
   [obj count]; // return 0
In theory a nil object can hide in your code for a long time if you only use methods that can return 0.
program··on An Illustrated History of objc_msgSend
As you can clearly see from the code it's perfectly acceptable in Objective-C to send a message to nil. This is a powerful feature that prevents the program from crashing but it is confusing for beginners.
program··on Italy is passing an internet sales tax
This is very sad, my country is very sad. The law states that "if you sell something in Italy then you are a permanent establishment on the Italian territory." Someone can say that if a server isn't hosted on the italian territory than the company that uses it can't be an "establishment" in Italy. It's not the case. According to the law if you use the italian network to communicate to italian IPs than you must pay.
program··on Twitter Tweet Button URL randomly resolves to a .torrent file
Reproduced from Italy just a couple of minutes ago.
program··on Google timer
I've noticed that is doesn't work if you aren't connected with your google account.
program··on Show HN: Tridiv - CSS 3D Editor
Safari on iOS 6 crashes every time I add a solid to the scene; which is kind of fascinating.
program··on Eigengrau
I find the Eigengrau to be a very relaxing color and I use it as the background of my desktop. It always puzzled me that it's not a pure grey but it has a little blue. I thought he had more sense that there was a little red because of the minimal amount of light that passes through the capillaries of the eyelids.

I suffer from epilepsy and often I see scintillating scotoma, visual snow and other strange light phenomena. Given this I came to the conclusion that my brain associate this color to a quiet mental state.

program··on Blocking Image Hotlinking, Leeching and Evil Sploggers with Url Rewrite
Unfortunately this approach does not work in HTTPS world. See https://tools.ietf.org/html/rfc2616#section-15.1.3

    Clients SHOULD NOT include a Referer header field
    in a (non-secure) HTTP request if the referring page
    was transferred with a secure protocol.
program··on Apple devices vulnerable to attack via bogus charger

   All users are affected, as our approach
   requires neither a jailbroken device nor
   user interaction
According to this article a user interaction is needed. You have to attach your phone to a third party charger in order to be infected. It will be more interesting if they can upload a real virus which then can affect other phones without user interaction.
← PreviousPage 2 of 7Next →