HNHacker News
TopNewBestAskShowJobs

430gj9j

53 karma · joined January 4, 2012

submissionscomments
430gj9j··on RFC 7049 - Concise Binary Object Representation (CBOR)
In the examples, 0x3bffffffffffffffff decodes to -18446744073709551616, which doesn't fit into int64_t. Why didn't they switch to bignums after INT64_MIN (-9223372036854775808) instead? Seems a bit asymmetric.
430gj9j··on New SARS-like virus is a 'threat to the entire world'
The full text is a little less alarmist: http://www.who.int/dg/speeches/2013/world_health_assembly_20...
430gj9j··on Older programmers are more knowledgeable, but harder to find
According to the original paper, 81% of SO users didn't provide their age, so to conclude that older programmers are more knowledgeable from this data seems unwarranted. The paper acknowledges however that SO population may not be a good proxy for the programming community in general:

Research into the nature of the SO population and its relation to the programmer population at large needs to be conducted, in order to support inferences to the programmer population. Further investigation is needed of how SO measures, such as user reputation and question scores translate in to programming knowledge and ability. Research on the relationship between age and knowledge on SO should be related to the existing literatures on aging and on the development of expertise.[1]

[1]: http://people.engr.ncsu.edu/ermurph3/papers/msr13.pdf

430gj9j··on C++ compiler accepts explicit constructor call
The programmer inadvertently used a vendor-specific feature. This is the key difference. Nobody writes perfect, standards-compliant code all the time, so the compiler needs to tell you when you are doing this.
430gj9j··on C++ compiler accepts explicit constructor call
A quote from Stroustrup:

"Use of a supplier's language extensions and non-standard-conforming features limits the portability of your code and can prevent you from choosing a new implementation supplier."

http://www.stroustrup.com/compilers.html

430gj9j··on C++ compiler accepts explicit constructor call
And also here: http://connect.microsoft.com/VisualStudio/feedback/details/7... And again: http://connect.microsoft.com/VisualStudio/feedback/details/7...
430gj9j··on UK Startup Community Interactive Map Launched by TechBritain
I'd love to see this with a little more curation. An example (there are more): calling Inmarsat a startup is a bit tenuous when they are LSE listed with a market cap of 2.8 billion.
430gj9j··on Make the Metric system the standard in the United States
This would be a great analogy if countries in grey shared a common language.
430gj9j··on The case for the iPad as a creation device.
The article opens by quoting the NYTimes claiming the iPad's keyboard is "abysmal for typing anything over 140 characters", yet fails to address this point anywhere. Is touch as fast and accurate as a keyboard and mouse?
430gj9j··on Keep encrypted files private even from governments demanding the password
The key is the same length as the data, making this a one-time pad rather than XOR encryption. http://en.wikipedia.org/wiki/One-time_pad
430gj9j··on Keep encrypted files private even from governments demanding the password
Presumably you'd have to store the keys somewhere, given that only a savant would be able to memorise them. That somewhere will probably as easy to seize as the encrypted data.
430gj9j··on C++ pitfalls
Yes. In a previous version I was trying to bypass string caching to make x==y return false.
430gj9j··on C++ pitfalls
All languages have pitfalls. Including the author's beloved Java. For example:

   String x = "foo";
   String y = "foo";
   // Appears to work but compares references
   System.out.println(x[0] == x[1]);
There's no substitute for knowing your tools well.
430gj9j··on Population Pyramids of the Whole World from 1950 to 2100 (made using Raphael.js)
Bear in mind you can't hover on a tablet.
430gj9j··on Google Go: Good For What?
Ask what isn't in Go that is in Scala. The Go authors deliberately left out certain features to focus on what they call "clarity of design". I don't see them ever adding XML literals for instance!
430gj9j··on Pythonect (dataflow programming lang based on Python) 0.4.1 released
http://www.pythonect.org/ FTFY
430gj9j··on Why should I have written ZeroMQ in C, not C++ (part II)
No copying here:

  struct person { int age; };
  std::list<person> people;
  people.push_back(person());
  people.back().age = 42;
430gj9j··on Don't be evil - Google pays £6m UK tax on £395m turnover
Last time I checked corporation tax was payable on profits, not turnover.

http://www.hmrc.gov.uk/ct/getting-started/intro.htm

430gj9j··on How many squares can you find?
This made me think: do browsers assume square pixels? So that an N by N pixel image will appear square when displayed? Or is that the responsibility of the OS?
430gj9j··on Display 100 Hello World Without Using Loops
You're right, Python isn't beautifully minimal. But the Scheme version is boring ;)

Rather than asking the interview candidate to use recursion for a problem that shouldn't be solved using recursion (unless in a language where recursion is the idiomatic iteration method), it would be better to ask about a problem that is best solved using recursion rather than printing "Hello world" -- perhaps something from Project Euler (http://projecteuler.net/).

430gj9j··on Display 100 Hello World Without Using Loops
Python version:

    exec "print 'Hello world'\n" * 100
430gj9j··on Javascript Regular Expression Editor
Bug: line 125 of application.js should read

if (index !== -1) value = value.slice(index + length);