Lottery Odds Question - <AUTHOR> In a lottery that let's you choose numbers between 1-70 for the five "white" balls, and numbers between 1-25 for the sixth "mega" ball, if after being drawn the white balls are ordered from least to greatest, what is the probability of getting exactly the lowest two white balls?
For example, let's say the winning numbers for the first five white balls when ordered from least to greatest is 1,2,3,4,5 and the sixth mega ball is 10. What is the probability of getting exactly the lowest two white balls 1 and 2 correct and no other numbers?
Note that this is different than the probability of getting any two numbers to match- this is the probability of getting the lowest two numbers to match. <comment><USER2> > _what is the probability of getting exactly the lowest two white balls?_

It depends on how you choose your numbers. We can assume the numbers drawn in the lottery are random, but the odds of you correctly getting exactly the two smaller numbers and no others depends on how you have selected the numbers against which you are matching those drawn.

<comment><AUTHOR> Let's say that the first five white balls are pulled from the first container containing 70 balls and that the sixth ball is pulled from a second container containing 25 balls. What is the probability then of getting exactly the two lowest numbered white balls from the first container?

<comment><USER2> I still don't understand your question ... there are several possible interpretations, and I don't know which one you think is the most obvious.

So here's one.

> There are white balls numbered 1 to 70.

> There are black balls numbered 1 to 25.

> I select 5 white balls uniformly at random without replacement.

> I select 1 black ball uniformly at random.

> I place all the balls in numerical order.

> What is the probability that the black ball is the third smallest?

But that description doesn't really seem to match the language you're using. You talk about "Getting exactly the two smallest white balls right" ... I have no idea what you mean by that. And what part is played by the black "mega" ball?

If my framing is right (though I suspect it isn't) ... the first supplementary question is: What if the selected white balls are numbered 1, 2, 3, 4, 5 and the black ball is numbered 2?

By the way, the hardest part about these sorts of questions is learned how to state them absolutely precisely. You will find that no matter how careful you are, there will be someone who finds an alternate interpretation. I'm not even convinced my statement above is completely water-tight.

Also, why are you asking? What's your application?

Finally, as I say, I suspect my framing is wrong, and that I really don't understand what you're asking. If you're serious about this, you need to think carefully about what's actually going on, break it down into very small steps, and try to be absolutely precise about each step. So far, I suspect I'm not going to understand your question well enough to be able to answer.

<comment><AUTHOR> Let's say W stands for white ball and B for black ball. Let's say we draw and order the white balls from least to greatest. It will look like this: W1 W2 W3 W4 W5 B1

I'm asking what is the probability I get the two lowest white balls W1 and W2 correct but get all other balls W3 W4 W5 B1 incorrect?

<comment><USER2> What do you mean by "get W1 and W2 correct"? I get the bit about drawing the balls and ordering them. I don't understand what you mean by "get them correct".

<comment><AUTHOR> That means that if those numbers are drawn randomly from the containers, I'm asking what is the probability that a person guesses those numbers right BEFORE they are drawn as happens in the lottery?

<comment><USER2> That depends on how the person chose their numbers. So now you need to specify how the person chooses their numbers. Are they choosing their numbers uniformly at random without replacement?

I still don't know that the black "mega" number has to do with this, and I'm still curious as to where the question comes from.

<comment><AUTHOR> Let's say the person chooses those numbers randomly and in the same way they are drawn (e.g. no replacement so number 1 can only be chosen once for the white balls).

The black ball is there just to get the exact probability estimate for the Mega Millions lottery.

To answer your question it comes from the Mega Millions lottery which draws 5 white balls and 1 black ball. And I'm curious to know what is probability I get first two numbers right.

<comment><USER2> OK, so the question is this:

Suppose I draw 5 numbers uniformly at random from 1 to 70, and suppose I do so twice. What is the probability that the smallest two numbers match, and no others?

So let a1<a2<a3<a4<a5 be the number from one draw, and let b1<b2<b3<b4<b5 be the number from the other draw. What is the probability that a1=b1, a2=b2, and a3, a4, a5, b3, b4, b5 are all different.

Is that your question?

How accurately do you need to know the answer? You can get an approximation quite quickly by simulation ... an exact answer will be horrible.

 _Edit: OK, I have answers, but it would be useful to know how accurately you need your answer._</comment></comment></comment></comment></comment></comment></comment></comment></comment>


ASCII Pronunciation Rules for Programmers [2008] - <AUTHOR> http://www.codinghorror.com//blog/2008/06/ascii-pronunciation-rules-for-programmers.html <comment><USER2> When I first started programming, I didn't know which of the two symbols / or \ was "forward slash" or "back slash", so I got into the habit of calling them "uphill" and "downhill", respectively. I still tend to use those terms when I'm working with people who aren't computer savvy, and those terms tend to be a bit more intuitive and help avoid confusion.

<comment><USER3> uphill and downhill assume going left to right. forward slash and backslash both assume going left to right.

How is this an improvement?

Maybe call them right-slash and left-slash, with the lean prefix implied? This would probably help our right to left language friends.

<comment><USER2> I'm a little ashamed to admit it, but I always had a hard time remembering where the "hinge" was on the slashes.

Let me explain: Assume that the slash begins like a pipe |. If the slash has a hinge at the bottom (like most people intuitively assume), then / is "leaning _forward_ " and \ is "leaning _back_ ". However, if, when you look at the slash, you assume the hinge is on the top, then it looks like / is "swinging _back_ " and \ is "swinging _forward_ ".

So until I figured out where people were putting the "hinge", "back" and "forward" seemed arbitrary. I know it sounds strange, but it was a great source of confusion for me.

Edit: The phrase "lefty loosey, righty tighty" also confused me until I figured out that "left" and "right" were relative to the direction that the _top_ of the screw/bolt moved, not the bottom.

<comment><USER4> It has nothing to with where the 'hinge' is. '/' is just 'slash'; it's the only one that existed before computers. '\' was invented so you could write the mathematical symbols for 'and' and 'or' as /\ and \/. Since it is a backwards version of the slash, it was named 'backslash,' and 'forward slash' later came about in analogy with 'backslash.'

</comment></comment></comment></comment><comment><USER5> Around ten years ago I worked as an instructor teaching people programming here in Sweden. My company decided I did such a good job they would send me over to their parent company in the UK to teach some classes there. I knew the material by heart so, no problem, I thought.

I quickly discovered, right in front of the class at the white board with marker in hand, with my first " { " written, that being fluent in English was NOT the same as being fluent in Spoken Programmer English.

My second realization was that almost nobody in the United Kingdom spoke a dialect of English that I could comprehend, but that's another story.

Bonus info: { } are called commonly called måsvingar/seagull wings in Swedish, which really gave me no hint at all what to call them in English.

<comment><USER6> Swedish also has a funny name for the @-sign, named after the trunk of an elephant. In fact, quite a few languages do. Here's a short sample from the Wikipedia article:

 _In Swedish and Danish the sign is known as the "snabel a" (literally trunk a), owning to the resemblance between the sign and the trunk of an elephant. In Norwegian the term most commonly used is "krøllalfa" (literally: curled alpha). In Greek the sign is known as "papaki" meaning small duck. In Slovenian, the most common word for it is "afna", colloquially meaning "monkey", much like in Polish. In Hungarian, it is called "kukac" meaning "caterpillar"._

<http://en.wikipedia.org/wiki/At_sign#Names>

<comment><USER7> And in the Netherlands, we call it a ape's tail (we use 'ape' both for monkeys and ape's.)

<comment><USER8> In Poland it's very often simply called "ape" (often giving e-mail addresses), before I often heard "elephant's ear".

<comment><USER9> Some people in Germany call it 'Klammeraffe', which would roughly translate as 'an ape that clings to something' or 'spider monkey'.

<comment><USER10> Finns often call it "miumau" (meow meow) because it looks like a cat's tail.

<comment><USER11> Hungarians call it "kukac" = worm because it also looks like a worm.

I think I'm going to start calling it cygnus because it looks like the accretion disk of a black hole.

</comment></comment></comment></comment></comment></comment></comment><comment><USER12>
        <> !*''#
        ^"`$$-
        !*=@$_
        %*<> ~#4
        &[]../
        |{,,SYSTEM HALTED

Pronounced:

         Waka waka bang splat tick tick hash,
         Caret quote back-tick dollar dollar dash,
         Bang splat equal at dollar under-score,
         Percent splat waka waka tilde number four,
         Ampersand bracket bracket dot dot slash,
         Vertical-bar curly-bracket comma comma CRASH.

<http://www.ascii-art.de/ascii/pqr/poem.txt>

</comment><comment><USER13> Another source of confusion is the meaning of the word "brackets":

      +----+</comment><comment></comment><comment>-----+</comment><comment></comment><comment>-+
      |    | []              | ()          |
      +----+</comment><comment></comment><comment>-----+</comment><comment></comment><comment>-+
      | US | brackets        | parentheses |
      | UK | square brackets | brackets    |
      +----+</comment><comment></comment><comment>-----+</comment><comment></comment><comment>-+

<comment><USER14>
      | AU | square brackets | parentheses |
      +----+</comment></comment><comment></comment><comment>-----+</comment><comment></comment><comment>-+

:(

<comment><USER15> Is there nothing commonly called just 'brackets' in Oz?

<comment><USER14> In high school, my maths teachers all insist ( ) are `parentheses`.

The sibling post's author thinks that ( ) are brackets.

Clearly there are two different populations here. That's why the need to explicitly specify which "brackets".

</comment></comment></comment><comment><USER16> ` as backtick is rare? I thought it was the standard.

<comment><USER17> Where are you from? I've actually never heard it before (in the US).

<comment><USER18> I'm from the US, but I think I know it almost exclusively from Unix shell scripts and Perl documentation, where `foo` is called the "backtick operator".

<comment><USER15> Yes, I think it could be your (our) tech context more than geographical; I came up through the unix and perl worlds and am in the US, and have ONLY ever seen that as 'backtick'.

</comment></comment></comment></comment><comment><USER19> It's also in (and probably a copy of) the Jargon File: <http://www.catb.org/jargon/html/A/ASCII.html>

<comment><USER20> Yes, The New Hacker's Dictionary is a distillation of the Jargon File. Both are maintained by Eric S. Raymond.

</comment></comment><comment><USER21> One of my co-workers uses "cash" for $. I think that's the worst possible choice for pronunciation since it sounds just like "cache", which is another thing you need to talk about fairly frequently.

<comment><USER22> Also could easily be mistaken for "hash".

</comment></comment><comment><USER23> This is a blessing for, I imagine, everyone who has learnt computer programming in a non-English-speaking country.

</comment><comment><USER24> I work with French programmers, so that opens an entire other can of worms. Colon becomes "two points" and semi-colon becomes "point comma".

<comment><USER25> As a French speaker it make total sense to me; it just describes it.

I just searched quickly how to explain that the semi-colon is somehow half a colon. I couldn't find anything.

<comment><USER15> I'm not a French speaker, but those terms make perfect sense to me also, even though I've only just heard them here for the first time.

</comment></comment></comment><comment><USER26> It's a little silly, but I've pronounced a '{' or '}' as a 'curly brace' ever since I played Cave Story[1], in which one of the main characters has that name. Before that, I think I called them 'curly brackets'.

[1]<http://en.wikipedia.org/wiki/Cave_story>

</comment><comment><USER27> I refer those interested in this topic to the INTERCAL character naming conventions, now hallowed by tradition and skirting the edge of madness. As a taster . is one-spot : is two-spot , is tail and ; is hybrid. # is mesh. <\- is known as an 'angle worm' and is pronounced 'gets'. It goes on from there.

<comment><USER20> These are in Jeff's chart. And really most of them shouldn't be: they aren't "rare" pronunciations -- they're non-existent pronunciations. Nobody uses them, except to point out how silly INTERCAL is. And rightly so, since INTERCAL was created to be unusable.

However, there are a couple that, despite the INTERCAL authors' best efforts, have entered common usage, according to the chart: "mesh" and "splat".

</comment></comment><comment><USER28> I don't know if I would call this a "pronunciation guide", in the sense that it doesn't tell you how to actually stress the syllables or say any particular letters. Instead, it's more of a "naming guide" or "verbalization guide" for glyphs that don't map to specific vocal patterns.

Nitpick? Yes. This is HN, after all.

</comment><comment><USER29> So am I the only one who calls "-" a tack? As in chmod tack R

<comment><USER15> Never heard that one before. "dash" or "minus" is all I've ever come across.

<comment><USER30> Minus always annoys me, because it's long and most times (e.g., chmod <dash>R )you're never actually minusing anything. *

* Some Solaris commands use plus and minus to add and subtract things, but a) everyone hates Solaris commands b) this breaks with convention, hence a).

<comment><USER31> I suppose 'minus' makes things slightly longer, but is there a way to distinguish between R and r without three extra syllables? Both are likely to come up when chmodding.

<comment><USER32> "Big 'r'" and "small 'r'"?

</comment></comment></comment></comment></comment><comment><USER33> No reference to {} as mustaches? Three years are a long time.

<comment><USER34> I've always called them 'curly brackets' which, on reflection, is a little like calling a keyboard a 'typey box'. Funny how long you can do something without really questioning what you're doing!

<comment><USER35> I call them curly brackets {} to distinguish from square brackets [] and angle brackets <>.

<comment><USER34> I'm a self-taught coder with no formal CS training, and as such have found over recent years that I've been lacking (among other things) some of the appropriate vocabulary to talk about programming unambiguously.

Consequently, I'm always on the look-out for more formal and concise terms where previously I may have used more simplistic language - in this case, 'braces', 'brackets' and 'parentheses' struck me as being the best way to describe {}, [] and (), compared to curly, square and normal brackets (as I've likewise always called them). <> will have to remain angle brackets though I think.

</comment></comment></comment></comment><comment><USER36> Some people pronounce "?" as "Huh"?

Might as well call it a "WTF mark".

<comment><USER37> Surely you're thinking of the interrobang‽

<http://en.wikipedia.org/wiki/Interrobang>

</comment></comment><comment><USER38> I have trouble believing that "apostrophe" is more common among programmers than "single quote"...

</comment><comment><USER39> In a standard italian keyboard layout the '\' is placed between TAB and ESC, and '/' is shift+7.

A lot of people think that '\' is the slash and '/' the backslash leading to some confusion among non-programmers (and some escaped characters here and there.)

</comment><comment><USER40> A related article:

<http://news.ycombinator.com/item?id=1181243>

Openstache and closestache are two very good names for { and }, primarily because they are shorter.

</comment><comment><USER41> "Ampersand" is apparently a corruption of "and per se and" which was the (now extinct) last line of the Alphabet Song a hundred years ago. Anybody can corroborate?

<comment><USER42> [http://www.etymonline.com/index.php?search=ampersand&sea...](http://www.etymonline.com/index.php?search=ampersand&searchmode=none)

</comment></comment><comment><USER43> He should have also listed "#!" AKA "shebang" / "hashbang"

<comment><USER44> There are also many different ways that people pronounce -> and =>, although it might vary depending on programming language.

<comment><USER22> How do you pronounce it?

I usually say "arrow", or "dash-greater-than"... but come to think of it, I very rarely have to ever actually say this.

<comment><USER45> => is known as a _fat comma_ or a _rocket_ in Ruby circles.

<comment><USER22> Rocket makes sense, but fat comma?

<comment><USER46> In Perl "=>" is (almost) a comma, i.e. { a => 1, b => 2} is the same as { "a", 1, "b" , 2 }. I assume Ruby with its Perl heritage has this to some degree.

</comment></comment></comment></comment></comment></comment><comment><USER11> Extra points for listing the INTERCAL names!

</comment><comment><USER47> It annoys me when people on TV use "forward slash" when reading out URLs. Makes we want to tell people that URLs never use backward-slashes!

<comment><USER48> Never?

<comment><USER47> RFC 1738

Other characters are unsafe because gateways and other transport agents are known to sometimes modify such characters. These characters are "{", "}", "|", "\", "^", "~", "[", "]", and "`".

All unsafe characters must always be encoded within a URL.</comment></comment></comment>


Lua 5.4.0 beta - <AUTHOR> http://lua-users.org/lists/lua-l/2019-10/msg00003.html <comment><USER2> We use lua 5.3 on an embedded Platform for scripting and it has been a roller coaster ride. Not a fun one, unfortunately. You want luasocket? The stable one is not compatible with 5.3. Packages are sometimes outdated (for years no updates) and there is no replacement. The lua point releases have breaking changes. The source code itself is a macro hell which is hard to debug. And the code is not very readable. The documentation lacks for some topics of you use the c api. I tried to implement some scheduling for c and lua threads.

Oh and one thing if you must use Windows... you better quit right away. I had to help my co worker Installing it with luarocks and it is a mess. to be fair it was easy on my Ubuntu machine.

The thing is lua on embedded has no rival. but god did it cost me some nerves.

<comment><USER3> > The documentation lacks for some topics of you use the c api.

I'm surprised to hear this. I'm doing a lot of Lua and I always thought the documentation is very succinct and complete. I really curious when issues you ran into.

> The thing is lua on embedded has no rival. but god did it cost me some > nerves.

You might take a look at [https://bellard.org/quickjs/](https://bellard.org/quickjs/) and [https://duktape.org/](https://duktape.org/). The latter seems oddly familiar if you've worked with the Lua C API.

<comment><USER4> My info might be a bit out of date, but something that surprised me when I looked into it was how little control I had over the embedded lua interpreter from my outer app. I basically had to hand it control by calling lua_pcall, and either wait for a result or manage a timeout from another thread.

I expected to be able to do things like tell Lua to run for X milliseconds or Y opcodes or whatever, but it didn't seem that anything like this existed.

So perhaps my disappointment with the documentation was really just disappointment that the implementation wasn't set up to do what I wanted in the way I wanted to do it. But in the course of coming to this realization, I also found the documentation frustrating and opaque.

<comment><USER5> Running for X opcodes isn't too difficult, but isn't immediately straightforward either. Instead of calling a function with lua_pcall, start a coroutine using lua_resume. Then, you can have a callback using lua_sethook and the LUA_MASKCOUNT option, which triggers the callback after a fixed number of opcodes. Inside the hook, you make a call to lua_yield. That forces the coroutine that was running to yield control to the outer app. The outer app can then resume the coroutine if desired.

There was a while that I wanted use this to design a programming-based video game, where simulated agents worked in real time. Most of the programming games I have seen use a fixed timeout, and kill any scripts still running after that time. What I was thinking was to instead have the script constantly running, and any slow scripts continue running on the next frame (e.g. all players get 100 opcodes per frame).

<comment><USER6> Thats clever. I used the same approach with lua_sethook to run a hook every X opcodes and check if time or memory constraints have been exceeded. But instead of yielding I used longjmp to terminate execution (basically like raising an exception and catching it a few levels up in the stack).

It's not bulletproof though and the script can still block e.g. when calling into native code.

<comment><USER5> Yeah, native code can block, and in those cases requires additional checks in that exposed native code. That runs into all the usual multithreading headaches, and depends on exactly which functions have been exposed to the lua interpreter.

The advantage to this method over longjmp is that the function call is still valid and can be resumed at any point.

</comment></comment></comment></comment></comment></comment><comment><AUTHOR> Main changes

\- new generational mode for garbage collection

\- to-be-closed variables

\- const variables

\- userdata can have multiple user values

\- new implementation for math.random

\- warning system

\- debug information about function arguments and returns

\- new semantics for the integer 'for' loop

\- optional 'init' argument to 'string.gmatch'

\- new functions 'lua_resetthread' and 'coroutine.close'

\- coersions string-to-number moved to the string library

\- allocation function allowed to fail when shrinking a memory block

\- new format '%p' in 'string.format'

\- utf8 library accepts codepoints up to 2^31

<comment><USER7> >\- utf8 library accepts codepoints up to 2^31

Interesting. Didn't Unicode restrict UTF-8 to allow encoding only 21 bits? Does it mean that it can now do 6 byte UTF-8 encodings? What kind of restrictions did it have before?

<comment><USER8> Comparing the documentation seems to verify this easily:

\- [https://www.lua.org/manual/5.3/manual.html#6.5](https://www.lua.org/manual/5.3/manual.html#6.5)

\- [https://www.lua.org/work/doc/manual.html#6.5](https://www.lua.org/work/doc/manual.html#6.5)

</comment></comment></comment><comment><USER9> Just recall that Lua versioning schema allows for breaking changes to point releases.

This has been both great for Lua as a Lua and one of its biggest challenges. It's allowed the language be constantly refined and tweaked; however, at the expense that it's super common for applications to complete break when upgraded to a point release.

[https://www.lua.org/versions.html](https://www.lua.org/versions.html)

</comment><comment><USER10> It's nice and all, but I'll be over here using LuaJIT.

<comment><USER11> why?

<comment><USER12> The performance difference is pretty stunning.

[https://luajit.org/performance_x86.html](https://luajit.org/performance_x86.html)

<comment><USER13> Indeed. Mike Pall blows them out of the water single-handedly. I wonder if Lua developers have learnt anything from him with respect to performance. I would like to see how Lua 5.4.0 would perform in comparison.

<comment><USER14> It is no surprise that the benchmarks on the LuaJIT website are going to show it ahead of PUC-Lua, is it? In truth the performance comparison is a bit more complicated than that. :)

For a pure Lua comparison LuaJIT is typically going to beat Lua by a large margin. For code that can be JIT compiled you might see ~10x performance improvements and for code that doesn't you might still see around a ~2x improvement because the LuaJIT interpreter is written in hand-crafted assembly language (PUC-Lua sticks to portable and standards-compliant C90).

But things get a bit more complicated if you add foreign C code into the mix. Under LuaJIT, the JIT compiled code that uses the LuaJIT FFI interface is the fastest, but interpreted code using the FFI is slower than interpreted code using the traditional Lua-C interface, and can even be slower than PUC-Lua using the traditional Lua-C interface. This means that when you are using LuaJIT you need to be very careful to make sure that your code is the sort of code that can be JIT compiled. If you hit a "not yet implemented" feature you can have a big performance degradation.

\</comment></comment></comment></comment></comment><comment>

Nevertheless, Lua 5.4 has brought significant performance improvements compared to Lua 5.3, specially in integer operations (including for loops). Another big change was that the `#` is now faster. For example, on my machine the following loop runs in 1.96 seconds in Lua 5.3, in 1.26 seconds under LuaJIT, and in 0.96 seconds in Lua 5.4

        local a = {}
        for i = 1, 1e7 do
            a[#a +1] = i
        end
        print(#a)

The new generational garbage collector is also a very big improvement. I've measured a 1.5x speedup on some GC-dominated workloads, where the final result was that Lua 5.4 would even edge out LuaJIT, which is still using the old incremental collector.

<comment><AUTHOR> > I wonder if Lua developers have learnt anything from him with respect to > performance.

It cannot be emphasized enough that PUC-Lua and LuaJIT have different goals. One goal for PUC-Lua is that it must be portable everywhere and be implementable in pure ANSI C (no platform or architecture specific calls). LuaJIT in contrast contains much handwritten assembly for the specific architectures it supports.

PUC-Lua also cares deeply about interoperating with C and hence why the Lua-C interface is formally part of the language spec, and as the parent thread mentioned, LuaJIT using the traditional Lua-C interface can be really slow.

That said, PUC-Lua has learned a lot from Mike Pall. It was Pall that helped them get fully yieldable coroutines across pcall boundaries. I'm sure Pall's lengthy analysis of unimpressive garbage collection performance in both Lua 5.1 and LuaJIT was read by all of them and a motivation for them to try the generational garbage collector now finally working in 5.4.

But finally, there is a new project called Pallene (not being pedantic, formerly known as Titan). It is inspired by all the lessons of LuaJIT. The name ' _Pall_ ene' is a nod to Mike Pall. Pallene is a statically typed sister language to Lua that is designed for performance and easy C/Lua bridging, but in a way that doesn't bring in all the downsides of JIT. The language is glued at the hip to Lua so there is also easy interoperability between Pallene and Lua code. Pallene introduces static types not for the sake of type safety, but for the purpose of inferring what things can be optimized. Pallene brings in a AOT compiler into the mix and generates optimized binaries. But these binaries also look like any other Lua/C native library so they are callable from normal Lua too and the user doesn't know if they were implemented in C or Pallene.

Pallene was previously discussed on HN here:

[https://news.ycombinator.com/item?id=18038619](https://news.ycombinator.com/item?id=18038619)

Also look for the original Titan talk from one of the Lua Workshops a few years ago.

<comment><USER14> We chose the Pallene name because it was another one of Saturn's moon names that sounded nice, and is pronounced the same way in English and Portuguese. The Mike Pall thing was just a coincidence although we certainly can't deny his influence, as you have said :)

</comment></comment></comment><comment><USER15> I use Lua via OpenResty / lua-nginx-module and in personal C projects for plugins and scripting. Some of these seem useful, like utf8 support and const variables.

For the multiple user data values feature, I've always found lightuserdata more useful than userdata, because it's not often that you need just one bunch of simple memory that can be freed without any other work. Rather, I almost always have more complex data, such as things that need manual cleanup like sockets, handles, etc. Or, the structure has pointers to other things that must also be cleaned up. What I'd like instead is the ability to pass a destructor callback to `lua_pushlightuserdata` so that it get's called when the pointer falls off the stack.

I don't use Lua threads or coroutines currently, so I don't have much to add there. What I do wish is that there were a way to clone or pass objects from one lua state to another to support parallelism. Basically, I'm thinking of it like the work Eric Snow is doing on subinterpreters in Python. Passing values (by copying, no shared memory) between lua instances.

One use case I had is loading a plugin that you then want to run multiple instances of in parallel with different arguments. Ideally, you wouldn't have to load the plugin multiple times (therefore calling the module level code multiple times). So I'd like to copy the entire lua state and then run each one with different arguments. There's no userdata, coroutines, or lua threads, so I don't have to worry about things that aren't possible to copy.

I got as far as looking into how to copy functions and then got busy with other things and stopped. Is there anyone else out there trying to introspect Lua function structures and copy all the opcodes, upvalues, etc?

<comment><USER3> I think that's what Lua Lanes if for. Haven't used it myself, but the descriptions sounds exactly like what you're looking for: [http://lualanes.github.io/lanes/](http://lualanes.github.io/lanes/)

<comment><USER15> Wow, thanks for sharing! Not sure why I didn't find this when I was looking. It does look like a very good match to my use case. I'll have to try it out.

</comment></comment></comment><comment><USER16> People that use lua, what do you use it for and why did you pick lua?

<comment><USER17> I've used it in many games.

It's a simple, but powerful language that uses basically two features (functions and hashmaps) to implement everything. Ex: script files are implicitly functions. Global variables are in a hashmap. Semantically it is very much JavaScript without all the surprises. Semi-technical users (artists and designers) can figure it out and go on to make surprisingly powerful features.

The binary code is small and fast. The standard library is small and most of it can be removed easily. Parsing source to bytecode is quick. Loading bytecode is very fast.

It is easy to embed. It's easy to contain it's memory allocations in an arena. It's easy to restrict what it can and cannot do. It's easy to interface with C/C++. It's extremely portable.

<comment><USER18> Your last line there is really one of the big keys. No other language is as easy to embed and interface with C/C++. The only real exceptions are some varieties of Lisp, but the "easily embeddable" ones tend not to be as mature, performant and robust as Lua.

I'm no particular fan of the language, but they do the "embed and interface with C/C++" better than anything else I've seen.

</comment></comment></comment><comment><USER19> Wish they could improve the language syntax. It's so unnecessarily verbose. Moonscript did a good job improving Lua.

<comment><USER20> Most of it I'm pretty okay with. The one big pain point is lambda definitions: you _have_ to do `function(x) print(x) end` each time, instead of `\x. print(x)` or something.

It sounds small, but with callback heavy or embedded DSL code it very quickly adds up.

</comment></comment><comment><USER21> This is only a beta release; final could still be a year away.....

</comment><comment><USER22> It seems that quite a lot of people use Lua. I liked the language, it's tiny and well-made. However, I wasn't happy about the tooling support. IDE plugins, documentation generators, lint checkers – all of this seem abandoned. Is there any similar language (embeddable, good C interoperability) with better tooling besides JavaScript?

<comment><USER23> [Nim][1] seems to be a potential option.

[1]: [https://nim-lang.org/](https://nim-lang.org/)

<comment><USER22> The language looks really nice. I especially like its strong-typing nature. It seems, though, that it won't be easy to embed – Nim compiler requires either gcc or clang.

</comment></comment></comment><comment><USER24> This is probably not the right place to ask but ..., given that Lua is commently embedded in games, anyone know of a sandboxed version? I'd love to provide a scripting language for user mods to a game but I'd like as much as possible to not have to trust the mods.

<comment><USER22> You can choose what parts of the standard library scripts allowed to use. Just exclude os/debug libraries, and that's it. Newer versions of the Programming in Lua book contain detailed instructions.

</comment></comment><comment><USER25> I'm looking through the new reference manual and there doesn't seem to be any mention of const variables, or any mention of how the new to-be-closed variables work. Do you just define the __close metamethod and lua takes care of the rest?

<comment><AUTHOR> I haven't tried them yet, but in the work reference manual, look at: 3.3.7 – Local Declarations and 3.3.8 – To-be-closed Variables

I think the syntax use is: local x <const> = 5 local filename <const> = "/etc/fstab" local fh <close> = io.open(filename, "r")

</comment></comment><comment><USER26> We use Lua 5.1 in an embedded system and it works great. We use only a few standard libraries and have several dozen of our custom libraries exposed as Lua APIs. Predictable memory usage is really good. It's several years since we picked the then current version of Lua and have had no reason to upgrade. What would be the motivations to upgrade to a new Lua version on an embedded system where there is a working version?

<comment><USER3> I don't think there's any reason to upgrade unless some of your dependencies require a higher version and backporting is more expensive that porting over all your existing code. Since it sounds like you expose libraries with your own code and you have full control over your ecosystem, I don't think it makes sense to upgrade. At least in my project I see no reason to switch away from LuaJIT (so ~5.1/5.2). It works perfectly well and I don't see why that would change.

</comment></comment><comment><USER27> Does this release influence LuaTex? Or rather, maybe, how is it going with LuaTex?

I've previously opted for LuaTex rather than "base" Tex or XeLaTex and I'm at the point where I'd happily stick to LuaTex and also learn some of it's more technical aspects.

</comment><comment><USER28> Unfortunately, we only care about LuaJIT, which is lagging behind.</comment>


Stagefrightened? - <AUTHOR> http://googleprojectzero.blogspot.com/2015/09/stagefrightened.html?repost=1 <comment><USER2> While this is certainly fascinating, it seems terribly irresponsible given the sheer number of unpatched devices out in the wild.

<comment><USER3> Unfortunately, majority of Android devices will never get patched because Google doesn't exert control over the OS.

Imagine if security patch for a normal PC needs to be written by Microsoft, approved by Dell / HP (OEMs) and Bestbuy / Fry's Electronics (carriers).

Personally I'd recommend Nexus phones for people who like Android, and avoid anything else.

<comment><USER4> Indeed. I wonder if widespread exploitation of this issue will finally disillusion the community with the supposed wonders of an open ecosystem. An single entity that can unilaterally release (or better yet, push) a fix to all users is starting to look really good right around now compared to the "democratized" approach where every company with a finger in the pie has the autonomy to sit on its ass.

<comment><USER5> > I wonder if widespread exploitation of this issue will finally disillusion > the community with the supposed wonders of an open ecosystem.

The problem is not that we have an open ecosystem; it's that we have multiple closed ecosystems with controlling entities of varying competence.

> An single entity that can unilaterally release (or better yet, push) a fix > to all users is starting to look really good

A single entity which can unilaterally push a fix to my phone is a single entity which can be ordered by a court to push malware to my phone.

> compared to the "democratized" approach where every company with a finger in > the pie has the autonomy to sit on its ass.

It's not currently democratized; it is, if anything, feudal.

What we need is for phones to me simply computers, with users free to update and upgrade them as desired.</comment></comment></comment></comment>


The Dropout Economy - <AUTHOR> http://www.time.com/time/specials/packages/printout/0,29239,1971133_1971110_1971126,00.html <comment><USER2> I'm gonna go with "probably not".

The article starts with a standard argument that schools suck, then launches into a libertarian utopia forecast. I'm not sure how you can have both a information economy AND people who can't put in the time at a school to learn.

Schools aren't some evil conspiracy to teach conformance, they're the only way to teach basic info to lots of kids. And if kids can't sit through it long enough to learn, the majority won't self teach either, no matter how much you want them to. So what do those people do?

There are other models for schooling, but covering classic reading/writing/math/history is still pretty important, and modern schools do a reasonable job of providing that the majority of kids.

<comment><USER3> Nice try, blaming those dumb students for an education system that's failing them. The problem is they _don't_ do a reasonable job of teaching the basics. That's why poor minorities in DC and other places are demanding school vouchers-- but as long as teacher unions care more about their jobs than students not shit is going to happen.

Education has been going to hell for the past 30 years (or longer) so please don't delude yourself into thinking anything is going to magically change. The only change will be new legislation that _restricts_ self-funded alternative education. (Maybe you've already noticed governments trying to shutdown food co-ops under the guise of "public health")

<comment><USER4> I think the truth is somewhere in between.

Yes, there are a ton of failing school districts, but it's not as if kids are clamoring to learn all they can and being told no. Kids aren't really motivated to learn the stuff (not that they ever have been in the history of education), and those schools aren't doing any motivating. It requires both parties to try.

I think the idea of fixing schools has, and will continue to be, examined to death. What no one seems to examine is the other half of it. How can we as a society stop perpetuating the "learning is uncool" myth? Maybe it's because a math competition will never be as exciting as a football game, maybe it's just part of human nature to be skeptical of intellectualism as a defense mechanism for the ego... I don't really know. But I don't think you can "solve education" without paying attention to that part as well.

<comment><USER3> But the cultural problem you're talking about is _caused_ in large part _by_ the structural problem. Students slack off because the system passes students along with impunity. Why bother studying math when you know you will get promoted anyway? The only way to fix that is to allows schools to kick poorly performing students out. There are plenty of students who want to do well but the system crushes them.

<comment><USER5> What do you propose they do with the kids they kick out?

<comment><USER6> I don't know what the parent proposes, but generally people propose that kids who read at a 2nd grade level, stay in 2nd grade.

</comment></comment></comment></comment></comment></comment><comment><USER7> The lead sentence is

 _Middle-class kids are taught from an early age that they should work hard and finish school. Yet 3 out of 10 students dropped out_

Anyone catch the logical and rhetorical flaw ?

First, we talk about how MIDDLE class kids are taught not to drop out.

Then we seemlessly move to _all_ kids.

And...surprise! Some of them drop out.

Because, duh!, not all kids are middle class kids.

After reading that much stupid in the first half of the first sentence I stopped reading the article.

<comment><USER8> Perhaps the author considers non-middle-class people to constitute (significantly) less than 30% of the population.

<comment><USER9> Not surprising. Most Americans consider themselves middle-class: poor people think they are lower middle class and rich people think they are upper middle class. This is why "the middle class is disappearing" is such an effective political message: most people identify with the middle class.

It probably doesn't help that the American class system is vague. There's no official threshold between the classes. In some countries, the "upper class" is, by definition, descended from nobility, so even a British billionaire would still be middle class.

</comment></comment></comment><comment><USER10> If I were asked (as the author here was) to put together a piece on "10 ideas for the next 10 years" as part of a series subtitled "a thinker's guide to the most important trends of the new decade" - and for a national magazine to boot - I would at least _try_ to make it tight and coherent, backed up by logical thought and good examples.

In this article, the author nowhere even states the theme he is trying to develop - instead, he presents a grab-bag of under-developed ideas, many of them cliched.

If you read the piece itself, I challenge you - quick now - to state its principal theme.

Here is my best guess: "Young people of all political persuasions are today increasingly rejecting middle-class ideals of school and work in favor of new forms of communitarian living by which they are returning to the soil and are otherwise seeking to escape the reach of nanny-state government."

This is just a guess cobbled together from fragments scattered throughout this piece.

What are those fragments?

Within a few paragraphs (about 1,000 words), we have a jumble of ideas that includes: 30% school drop-out rates; educational stagnation; projections of "fiscal doom;" jobless recovery; New Deal programs about to "starve;" sputtering industrial agriculture; millions of families living "off the grid;" food-distribution systems based on ancient Mayan know-how; communes and co-ops avoiding the nanny state; bourgeois rebels; exploding home schools; self- sufficient vertical farms built from scrap; an underground economy using barter/virtual currencies; libertarian "hacktivists; ever-increasing productivity levels; a surge in home jobs that will revive suburbs that are today "ghost towns;" fewer private homes and more "cohousing communities;" "gated communities" effectively seceding from their municipalities to pursue their own view of the good life; "broadband socialism;" a "new individualism on the left and the right; "freeganism;" "cage-free" families; and 23-year- olds plotting a cultural insurrection that will knock American society "off its axis."

It all makes the head spin (not the ideas themselves, about which I do not comment, but the way in which they are presented). When it is all said and done, who knows what the author really intended? He makes you work really hard to figure it out and then leaves you with a sense that the effort was not really worth it.

For some excellent guidelines on good essay writing (in this case, for undergraduates), see this splendid piece that got few HN upvotes when it ran (at an odd time, I think) but sets forth fine guidelines for aspiring students writing in this format: [http://www.themonkeycage.org/2010/02/good_writing_in_politic...](http://www.themonkeycage.org/2010/02/good_writing_in_political_scie.html).

</comment><comment><USER11> _Imagine a future in which millions of families live off the grid, powering their homes and vehicles with dirt-cheap portable fuel cells._

Fuel cells are for energy storage, not generation. Something has to make the hydrogen (or hydrocarbon) to power them. Also, fuel cells use platinum as a catalyst. You know, rare expensive stuff that has to be dug out of the ground, processed, and refined before it can be shipped to factories that build fuel cells.

Living off the grid would require land for solar cells and/or wind turbines, and energy storage mechanisms for when it's neither sunny nor windy. Building this stuff requires factories (again), raw materials (again), infrastructure, and R&D. A small community can't afford these things. And that's just for basic stuff like electricity and transportation. The small communities could solve this by banding together and contributing resources to a collective pool. Some sort of federated system...

 _Faced with the burden of financing the decades-long retirement of aging boomers, many of the young embrace a new underground economy, a largely untaxed archipelago of communes, co-ops, and kibbutzim that passively resist the power of the granny state while building their own little utopias._

So... what happens to the old people? How do these small communities trade? I'm guessing quite a few will be landlocked. If trade is limited, how do these little utopias have modern medicine? An MRI machine needs to be topped up with liquid helium to maintain its superconducting coils (which are manufactured in factories-blah blah blah). Contrast agents use rare elements like gadolinium.

The writer doesn't seem to realize just how interconnected the world economy is. Almost nothing I own was made anywhere near where I live. I can't start my day without touching something built at least 1000 miles away.

<comment><USER12> There's been a lot of serious talk about living off the grid since the '60s. Trouble is the grid is an engineering marvel that delivers a heck of a lot of utility. (OK the pun is intended, but still informative.) Living off the grid is likely to remain the provence of dedicated hackers for a long time to come, not something for the masses.

</comment></comment><comment><USER13> This should be titled "How I learned to stop being afraid and love the new upcoming mad max world."

I wonder what those new and exciting jobs will be in that post apocalyptic world the author pines for. Sexual slavery? Hunting rats for meat and fur? The technically inclined can scavenge parts from rusting machines built in the magical old times and try to fashion some kind of working vehicles out of them. Maybe the more artistically inclined can try being jesters to the local warlord.

The relative prosperity of our current lives depends on the incredible interconnectedness of society which allows high efficiencies by having people specialise and become very efficient in some very narrow areas of expertise. Just think of an ordinary $600 computer and imagine the tens or hundreds of thousands of engineers whose specialised knowledge went into making it. It is only a highly complex and interconnected society that can come up with something like that.

And if most people start "living off the grid" or disconnecting from society, or if we stop training our children how to live in society (which is what school is supposed to be for), you better get ready for types of poverty that you have never imagined even in your worst nightmares.

Oh and if everybody starts dropping out of school and society, good luck coming up with those "dirt cheap fuel cells."

It is very disturbing how a lot of people are getting a bigger and bigger hard on for some kind of an Armageddon event.

<comment><USER14> That definitely sounds better than raising the top marginal tax rate by 5%.

</comment></comment><comment><USER15> Reads like a concept for a Cory Doctorow novel to me.

I dislike that the author is simply stating all these amazing and utopian things that are going to happen without much in the way of facts to back it up. It sounds like his dream more than anything concrete.

<comment><USER16> Wow, you read my mind.

</comment></comment><comment><USER17> I often rate articles on "stupidities per paragraph" or even, in extreme cases, "stupidities per sentence". This is the first article I've read that can be accurately described with "stupidities per character".

<comment><USER18> So you're saying there are at least ~6,500 identifiable stupidities in this article? Of course you're not.

Point being: hyperbole has value, for this author and for you.

<comment><USER19> I'd say shalmanese is a far better writer than the author, based on the samples I've seen.

</comment></comment></comment><comment><USER20> I don't think the author realizes how expensive it is to abandon society. I certainly would love to live in the middle of the forest with my own little hobby farm and pasture (and internet connection, of course) but for me to continue to work in a tech field, even remotely, I need things from the outside, like shingles, nails, plywood, hard drives. All together I probably need about $100k to $400k, depending on what type of living conditions I want, and that is with me still working as a knowledge worker on contract.

"Encrypted Digital Currencies" psshh. If the courts are not their to enforce ownership, the currencies will never take hold. It my as well read "Encrypted Digital Monopoly Money". The only type of currency that could possibly hold value for an semi-extended enough period of time would be some really stable MMORPG, but even there I'm grasping at straws.

<comment><USER21> I could see something like Facebookbux taking hold. Assuming FB actually launches a payment system, and their effective fees aren't too high.

I think one reason FB's payment system has been so long in coming is that they've been thinking through all the implications of being a parallel currency.

I'm guessing at that, but it seems likely.

<comment><USER22> They already exist and are called facebook credits: <http://www.facebook.com/help/?page=1038>

<comment><USER21> Hey, I'd missed that Farmville is accepting FB Credits now. That's pretty big.

They hadn't truly launched the credit system in a real sense. It existed, but was so low profile as to be non-existent, which I assumed was intentional. But with Farmville signing on, that's a pretty real launch.

The fee structure is still exhorbitant, though. Again, maybe intentional, to prevent it from being a practical parallel currency.

<comment><USER19> Probably intentional because that's their estimation of the demand curve -- their customers are app-writers who have to make a living off of facebook.

</comment></comment></comment></comment></comment><comment><USER23> Everyone I know who leads the kind of lifestyle this article is touting is a drop out, yes. Trouble is, they dropped out of grad school, not high school.

</comment><comment><USER24> _Yet 3 out of 10 students dropped out of high school_

I hate this statistic. I've known several people that dropped out of high school to get a GED instead. (It was faster for them and they were sick of school.) Others had to drop out of school because their family kicked them out of their house at 18. Both of them got GEDs later.

<comment><USER18> I'm among those students who dropped out of high school to accelerate my escape. I guess the phrase drop out hasn't dropped its negative connotations, so the author was using it to grab attention. But the essay is really about alternative paths to life goals, which is what many 'high school dropouts' are after.

<comment><USER25> I also dropped out of high school (and never bothered to get a GED; I went to college for a while and then dropped out to do a startup, so I've ended up with neither diploma).

It's kind of fun being able to put "high school dropout" on forms, while not being a deadbeat.

<comment><USER18> I'm impressed you got a college to accept your application without some kind of high school equivalency certification. How'd you manage that?

A few years out of school, however, and it's become very clear to me that "I just worked on this project for 6 months where we learned XYZ, had some hard times and eventually failed/succeeded/moved on." is much more attractive to the kind of people I want to work with than "I graduated cum laude from XYZ special university."

<comment><USER25> I was 16. MIT doesn't really care about high school diplomas. I'd already done 1580/1600 SAT and had a grad student and associate prof at MIT write letters of recommendation based on performance in a summer program (social engineering...)

</comment></comment></comment></comment></comment><comment><USER26> While the author's analysis of the current situation is fairly accurate, his predictions seem to me to be wildly off.

There's a pretty strong movement going on, bringing scientific method to teaching. It's chronicled in a great NYT article: [http://www.nytimes.com/2010/03/07/magazine/07Teachers-t.html...](http://www.nytimes.com/2010/03/07/magazine/07Teachers-t.html?ref=magazine&pagewanted=all)

Basically it boils down to:

1\. Find good teachers, based on how much their students improve. (Students of the top 5% of teachers improve test scores _a full year_ more per year than students of the bottom 5%).

2\. Analyze what the good teachers do that works better than what other teachers do. (For a small example: Stand still while giving instructions: moving around distracts).

3\. Teach these techniques to other teachers, and analyze the results.

This process, if scaled, seems to me to have far more potential for improving the current system, than any wild-eyed tech-mediated vision of home-schooling [not to knock home schooling: it works great, but it ain't gonna scale to anywhere near a majority of the population].

</comment><comment><USER27> All the nonsense aside I think it's true that people are no longer happy with "one size fits all" kinds of policies and institutions. This is not a bad thing and is simply one of the byproducts of improving technology that empowers individuals to pick and choose what fits them best be it education, food, clothes, etc.

<comment><USER19> If you're referring to the current state of unease within the electorate, I think it's the exact opposite issue -- how many times have you heard someone say "too much change"?

<comment><USER27> Politicians are a really poor metric when it comes to measuring change. They are always at least 2 decades behind the times and I can't really blame them for it since the people that put them in office are in their late 60s.

<comment><USER19> I'm not talking politicians, I'm talking the tea partiers -- the world's changing and it's not easy for everybody. A feeling that the world is changing and the easy ride we had is going away seems to be a powerful undercurrent there, to me at least. YMMV.

<comment><USER27> The world is always changing and only those with no historical perspective cling to bygone days.

<comment><USER19> Well, certainly I agree.

</comment></comment></comment></comment></comment></comment><comment><USER28> I'm still amused by liberal arts majors who somehow think that you can't work in the technical fields without a degree. Sure, a degree helps, but if you know what you are doing, it's not required.

Now, I know some really awesome people who went to college, and claim that they learned a lot there, I'm not saying it doesn't have value. hell, all other things being equal, I'll pick the applicant with a degree over the dropout, when I have the chance. But I also know many programmers and SysAdmins who didn't go to college, and a few who didn't finish high school. We don't need to live 'off the grid' mad max style. Not having a degree means that you will need to do real work for retail wages, for a while, but once you have experience, you get to upgrade to real wages.

</comment><comment><USER29> It took me approximately sixty seconds on Google to bring up a page from the Census Bureau, breaking down income according to education level:

[http://www.census.gov/hhes/www/cpstables/032009/perinc/new03...](http://www.census.gov/hhes/www/cpstables/032009/perinc/new03_001.htm)

The median earnings of an American over 25 with less than a 9th-grade education is $18,180. For a high-school diploma or GED, it's $27,963. For a bachelor's degree ("for a lot of them, an overpriced status marker and little else", says Salam), it's $48,097.

In the sample from this survey, the folks with less than a 9th-grade education represented about 5% of the total; does Salam really have any evidence that 5% of the US adult population lives cheerfully off subsistance agriculture and cryptocash?

</comment><comment><USER30> This article is too rooted in the middle class perspective for my tastes. To me the education system isn't failing these kids -- it's the other way around. They goto pretty good/safe schools and simply don't want the education being offered because they think they can beat the system. Probably many of them can because they have a safety net that allows them to reconsider their options down the road. It's the poor minorities who have dramatically higher drop out rates we should be considered about. If you don't have many opportunities in life you should maximize the "free" public education you can get and make the most of it.

<comment><USER18> Do you find it reasonable to burden a 5-year-old with the responsibility of maximizing the public education he is being offered? A 10-year-old?

</comment></comment><comment><USER31> When did Neal Stephenson start writing for Time?

<comment><USER32> That was what I was thinking - except stuff Stephenson writes about in Snow Crash that seems similar to what happens here is after some kind of societal meltdown.

</comment></comment><comment><USER33> The problem I see with this, is that the most talented middle class folks are still employed. It's these talented people who have the drive, creativity, and resourcefulness to home-school well, and to build new communities. Until and unless they are out on their butts, I don't think we will see this type of positive societal transformation.

It's likely we'll see more: crime and despair, and that all of those unemployed former worker-drones that the school system wrought, will increasingly look to the government for subsidies.

</comment><comment><USER34> Rather doomy for my taste, but I think we are heading towards a complex future something like this - closer to cyberpunk than to Star Trek. Even though the current recession is a temporary affair, there are good reasons to be concerned about growing technological unemployment and its effects in the next few decades, especially upon white collar "knowledge workers".

<comment><USER35> The economy is starved for capital. Rich folks are hoarding it.

If we don't get all that capital out of the trust funds of the rich and back flowing through the economy, yeah, we're headed a dystopian future.

</comment></comment><comment><USER18> It's couched in pretty exciting/revolutionary/utopian language, but are the ideas really more likely to become mainstream now than at any time in the past? Seems like today's spin on <http://en.wikipedia.org/wiki/Turn_on,_tune_in,_drop_out>

</comment><comment><USER36> Very good article. I am surprized Times and CNN published it, given their track record for crap. We better get ready for the future. Go with the flow or risk being left behind with the old desintegrating structures. Same thing for our belief structures. Hehe.. this one is gonna be a biggie.

</comment><comment><USER35> The writer of this article is a National Review blogger. Jonah Goldberg is one of the editors.

<comment><USER37> Point being? I hope I'm missing something, and mentioning the writer's other activities and associations isn't a substitution for evaluation of the content.

<comment><USER38> True, but it is helpful for evaluating what's useful to read.

</comment></comment></comment><comment><USER19> tl;dr:

Get off my lawn!</comment>


PC Shipments Post Steepest Decline In History, Now Lower Than Whale Shit - <AUTHOR> http://ctovision.com/2013/04/thanks-in-large-part-to-windows8-pc-shipments-post-seepest-decline-in-history-worse-than-all-estimates/ <comment><USER2> I hate to pass up a chance to point out Microsoft's failings, but "its the economy, stupid":

from 'Chart Book: The Legacy of the Great Recession'

"In the fourth quarter of 2012, the demand for goods and services (actual GDP) was about $975 billion (5.8 percent) less than what the economy was capable of supplying (potential GDP). This large output gap, which is manifested in a high rate of unemployment and substantial idle productive capacity among businesses, is the legacy of the Great Recession. Congressional Budget Office projections show the gap closing slowly over the next several years as actual GDP grows only moderately faster than potential GDP.

GDP grew at a 0.4 percent annual rate in the fourth quarter. A period of growth of 4 percent or better would be needed to propel the economy back toward full employment more rapidly."

[http://www.cbpp.org/cms/index.cfm?fa=view&id=3252](http://www.cbpp.org/cms/index.cfm?fa=view&id=3252)</comment>


Ask HN: New role for a software developer - <AUTHOR>

Hi, I 'm a software developer with 6 years of work experience. After working for 6 years as a developer I want to try and do something else. What that might be is not clear to me.  At this time I have only two ideas , working as a Pre-Sales engineer or MBA.  I 'm still not sold on MBA even though i like the idea of doing so. I 'm not particularly convinced because I would be moving into an unknown territory. If I take the MBA route I would like to work with one of the top consulting firms. And that is what I aspire to do in long term also, work for a consulting firm.<p>Can someone please give me some insight both good/bad about pre-sales engineer & consulting profiles. Any other recommendations would also be great.. Thanks for reading <comment><USER2> I'd consider an evangelist role, but this does require having a slightly raised profile in terms of speaking engagements, OSS code, and blog writing. But it's a good alternate path from day to day code writing.

Also, I think there's a strong need in the industry or Product Managers and heads of Product who come from a development background. Many of the people currently doing Product Management just sort of fell into it via Sales or Customer Development roles. These individuals are not equipped with the technical knowledge to deliver quality software. If you ever want to start a company, a strong background in Product Management and a few successes under your belt will go a long way.

</comment><comment><USER3> what do you like to do? Lets say that you have enough money to lead a comfortable life in a place you like. What would you be doing to kill time?

<comment><AUTHOR> I 'm not sure where this is leading to or how does it pertain to my situation??

<comment><USER3> its very simple. do what you like to do. Suppose, you have all your needs met, such as food, shelter. You will be doing something to engage yourself. That may be what you like to do. btw, even that may change over a period of time. Basically, if you start doing what you love to do, eventually you may start doing that fulltime. When you enjoy doing something, it doesn't feel like work. It is fun. Life should be fun.</comment></comment></comment>


How did organized crime attempt to ransack PayPal in the early years? - <AUTHOR> http://www.quora.com/How-did-organized-crime-attempt-to-ransack-PayPal-in-the-early-years

<comment><USER2> It is interesting to hear that eBay originally was against the use of PayPal. Did they at one time have a competing system that they were trying to push? It seems to me that anything that would allow users to simplify their payment would be a good thing. I am guessing that PayPal originally wanted to take credit cards directly (?).</comment>


The First Caucasian Samurai - <AUTHOR> http://en.wikipedia.org/wiki/William_Adams_(sailor)

<comment><USER2> This story gave rise to one of my most favourite novels, Shōgun, by James Clavell. It's a great story about conquering the cultural divide. Not entirely sure why it was linked on HN but it's certainly interesting.

<http://en.wikipedia.org/wiki/Shōgun_(novel)>

It's also an interesting exercise in cultural expectations; even now, with our small world, there are still very different expectations with, say, setting up a business or even just conducting business or going to work (or even living) in Japan or China (or many other countries) and that of the same in a "Western" country. Even then, doing business in America is, it seems, quite different from doing it in Australia or the UK or Continental Europe.

Just goes to show that even though we feel we get closer as an international society, many things highly resist change or adapt in quite different ways.

<comment><USER3> "Not entirely sure why it was linked on HN but it's certainly interesting."

Justin (justin.tv) mentioned Shogun in his Inc.com interview.

</comment></comment><comment><USER4> He was not the first Foreign Samurai though, an African preceeded him: <http://en.wikipedia.org/wiki/Yasuke>

</comment><comment><USER5> In a weird way, William Adams has had a huge effect on most of the good things in my life.

As liedra noted, he is the inspiration for the main character in Shogun. When I was about 9 years old, I first came across Shogun (the book) at my public library. It enchanted me and I've read it many times since then.

It was my first experience with anything related to Japan and it completely fascinated me. I tried to learn Japanese on my own as a kid and finally learned it for real in college. Through my wife, kids and career, it's fair to say that almost half of my life has been a Japanese experience.

</comment><comment><USER6> We should get a book thread going. Shogun is definitely one of my favorites.

<comment><USER7> It's currently on my waiting list. Right now I'm halfway through "Musashi", which I'm finding quite motivational. I'm not sure how the two books compare though.

<comment><USER2> I preferred Shogun a lot more over Musashi. I know the second is a classic, but the first one was a much more engrossing story to me (despite its historical inaccuracy). :)

</comment></comment></comment><comment><USER8> Everyone who saw the Tom Cruise movie knows that the last samurai was white, too. :P</comment>


FreeBSD Gains KTLS Support - <AUTHOR> https://svnweb.freebsd.org/base?view=revision&revision=351522 <comment><AUTHOR> This is the upstreamed version of the code that Netflix uses on its Open Connect CDN. In addition to software crypto, it also has support for inline hardware TLS offload (eg, where the NIC encrypts the stream as it is sent).</comment>


Gobekli Tepe: The World's First Temple? (2008) - <AUTHOR> http://www.smithsonianmag.com/history/gobekli-tepe-the-worlds-first-temple-83613665/?all?no-ist <comment><USER3> I find a couple of the comments to that article posits something interesting - at least to think about:

This site, according to the article, was built by carving these stones, erecting them, then covering them up - the repeating the process on top of the covering, ultimately leading to this "hill". The carvings are of "dangerous creatures". At the bottom of the pits, they found limestone floors (which in the article they speculate it might be a large hunter-gather cemetery). So - why all this effort?

In the comments, a couple of people speculate (and that's all it is - <USER2> speculation with no other reasoning) that this site is a large "do not disturb, do not dig here". These speculation go on to suggest that, much like today we are trying to come up with symbols and/or symbology to denote our burying sites of long-lived radioactive waste - that perhaps something of this nature was done by these ancient people.

Again - pure speculation, with no facts or other understanding to back it up - but the idea is interesting: Is it biological in nature? Some kind of ancient foe entombed to keep it from killing these hunters? Maybe an ancient "natural nuclear reactor" site that killed people with radiation? Cthulhu?

Whatever the truth is (and the truth will likely be very mundane) - the above could easily be interesting fodder for a science fiction or fantasy author!

<comment><USER4> It's been a few years, but I remember learning about Gobekli Tepe in one of my humanities classes in college. The theory I learned is that it was a non- permanent gathering/ceremonial site (for what reason isn't exactly known), but this article neglects to mention one very interesting thing - there's trace evidence of beer at the site!

Makes you wonder what grains were used for first, beer or bread... Also the role that alcohol plays in the rise of civilization. Would these people be warring or otherwise combatitive if they didn't gather every year to drink and feast?

[http://www.livescience.com/25855-stone-age-beer-brewery- disc...](http://www.livescience.com/25855-stone-age-beer-brewery- discovered.html)

<comment><USER5> Since people can get alcohol from palm wine [which is pretty universal in warmer clines] already maybe initially from an accidentally fermented vat, might people use grain primarily for food and only use it for alcohol if they had surplus that would go bad if unused?

</comment></comment></comment><comment><USER6> The most impressive part of Gobekli Tepe is that the site was built by hunter- gatherers -- people with no granaries, no specialists, no taxes or central authorities. This was a very impressive display of community will, and reveals that hunter-gatherer societies were potentially capable of much greater accomplishments (while remaining hunter-gatherers) than we'd previously known of or imagined.

I'm reminded of MFAC -- the Maritime Foundations of Andean Civilization hypothesis -- which argues that Peruvian/Incan civilization began with fishing instead of agriculture: another of those things that supposedly can't happen. Granaries are very important, but perhaps less so than we think...

<comment><USER7> What proof is there that they were hunter and gatherers (aside from an assumption based on timeline)? Isn't building an extensive permanent structure a signature of settled people?

<comment><USER8> That it's the _only_ permanent structure of its kind from that period, and that every other type of artefact from the era we have found so far is very different.

<comment><USER7> But the amount of resources required to build that type of structure is not present in a H&G society. Those societies tend to be small groups. Quarrying large stones requires a lot of resources, which is only present in a settled society.

<comment><USER9> This is overly simplistic imo. We know that H&G groups periodically congregated and cooperated in groups far larger than a single band, such as to share in hunting the seasonal peak of herds. It's not that much of a stretch to believe they'd periodically congregate to advance a construction.

<comment><USER10> Umm...Id say it's a stretch. Wanna hunt together? Wanna quarry some stone and build a temple? I don't think we are talking about apples and apples here.

<comment><USER9> I disagree. I think it's entirely likely things started along the lines of "We gather here every year this season to share in the peak hunt festival. Let's make a mark upon this place" and over a few centuries that grew motivating enough for people to incrementally build more elaborate megalithic structures. This is just my view, and I'm certainly no anthropologist. But I would point out this narrative exactly matches what we see at Gobekli Teki: layers of megalith construction, each covering and supplanting the previous.

</comment></comment></comment></comment></comment></comment></comment><comment><USER11> I'm so proud of this as an edessene, and as a human. The assumption was that food civilised us, but Göbeklitepe says that civilisation came first, then we fed it.

</comment><comment><USER12> Gobleki Tepeh is such a fascinating site. I love the way it both throws a spanner into historical understandings and alludes to them in interesting ways.

It's not just _before_ agriculture, it's _just before_ agriculture, almost moments before. This is also the area where historians think it first happened. That leaves room for curious ideas like agriculture as a byproduct os civilization rather than the other way around.

The next oldest settlements are newer, less ornate and well.. _settlements_. No one can even figure out what Gobleki Tepeh was. Doesn't seem to be buildings. The next oldest sites are the likes of Ain Ghazal & Jericho. These were proto-cities with dwellings. They come with some pretty weird ancient art, but at least we can imagine what these people were up to. They grew crops, lived in houses, buried dead, made statues. They fit into the narrative mould history. Megalithic outdoor sanctuary on a bronze age scale before known agriculture or settlements, at a time when people were supposed to be living in small bands? Beautiful mysteries.

</comment><comment><USER13> Amazing article, but for all that's good and your own mental health, don't read the comments.

</comment><comment><USER14> "Predating Stonehenge by 6,000 years, Turkey's stunning Gobekli Tepe upends the conventional view of the rise of civilization"

Ha! It is hilarious to see west measure 'rise of civilization' against some dumb set of stones wedged by people who probably didn't know how to write. Plain fodder for insular minds.

Civilizations in the middle east (such as the now broken Syria) and even Indo- Srilankan subcontinent have been known to have practiced and even have written transcripts of things like heat sensing weaponry, a "nuclear standoff" and an equivalent of what we call theory of atoms -- read about _brahmastra_ or _brahmand_ , for example, in Mahabharat[1].

[1] [https://en.wikipedia.org/wiki/Mahabharata_(disambiguation)](https://en.wikipedia.org/wiki/Mahabharata_\(disambiguation\))

<comment><USER6> If we're going to argue that the Mahabharata is an account of nuclear war, we need to remember that it's extremely similar to the Irish _Cattle Raid of Cooley_. It's not an account of ancient Indian greatness; it's an account of the death of a previous civilization, which Proto-Indo-European-speaking peoples witnessed from the periphery, recording it in forms that became the garbled accounts surviving in India and Ireland.

<comment><USER14> > If we're going to argue that the Mahabharata is an account of nuclear war, > we need to remember that it's extremely similar to the Irish Cattle Raid of > Cooley.

Correct! I would rather measure up 'rise of civilization' against both texts than a stupid set of stones with nothing written on them -- which at best seems like a partial rise of civilization. Hence, the hilarity.</comment></comment></comment>


Chinese satellite is one giant step for the quantum internet - <AUTHOR> http://www.nature.com/news/chinese-satellite-is-one-giant-step-for-the-quantum-internet-1.20329 <comment><USER2> > Eventually, quantum teleportation in space could even allow researchers to > combine photons from satellites to make a distributed telescope with an > effective aperture the size of Earth — and enormous resolution. "You could > not just see planets," says Kwiat, "but in principle read licence plates on > Jupiter's moons."

Uh, what? What does entangled photons have to do with interferometry-based astronomy? Can somebody explain to me how this could be achieved?

<comment><USER3> It lets you bypass some classical limits. It's a well known idea. For example, John Preskill mentioned entangled telescopes in a non-technical talk back in February [1].

A specific case is "NOON" states [2]:

> _NOON states are an important concept in quantum metrology and quantum > sensing for their ability to make precision phase measurements when used in > an optical interferometer._

\---

Here's an example that doesn't exactly use entanglement, but does use quantum stuff to give you the general flavor. Suppose you have an optical setup like this:

              B
              |
              v
        A --> ◩ -----> D1
              |
              |
              v
              D2

When a photon is emitted from A, or B, it passes through a beam splitter then continues on to the two detectors and triggers one of them. If the detectors are classical, then there's no way for you to distinguish whether A or B emitted the photon. Both are a 50/50 split. But if the detectors can store their readings at various times as quantum information and keep that information coherent, then you can bring the stored qubits together, simulate un-applying the beam splitter, and voila! The same basic idea applies to telescopes: photons from different sources spread out in slightly different ways, and we can undo some of that spreading with quantum computation.

1: [https://youtu.be/lN8zT_Yk5sg?t=3m58s](https://youtu.be/lN8zT_Yk5sg?t=3m58s)

2: [https://en.wikipedia.org/wiki/NOON_state](https://en.wikipedia.org/wiki/NOON_state)

<comment><USER4> Thanks, I actually understood that!

</comment></comment></comment><comment><USER5> So what if someone decided to DOS quantum communications by spying on all of them? You don't need to be successful at deciphering the communications; you just need to tamper with many of them to make a whole bunch untrusted, and eventually others stop trusting the whole channel because most messages have false interception positives.

<comment><USER6> Exactly what I was thinking, if it's easy to tell they've been intercepted by a third party that infers it's possible to do it so what's to stop a DOS attack making it useless?

<comment><USER7> > if it's easy to tell they've been intercepted by a third party that infers > it's possible to do it so

This is a logical fallacy. Furthermore, it says nothing about how difficult a DOS attack would be to perform.

</comment></comment></comment><comment><USER8> This is a pretty interesting article! I have some questions, though:

1\. What properties of space facilitate quantum experiments more than terrestrial environments? Reduced gravity? Vacuums?

2\. How does the satellite create pairs of entangled photons? I missed the memo that we could control entanglement...

3\. When two photons are entangled, what kinds of properties about them are useful to observe/control, that give us information about or control of the twin? All I can think of are positional properties like position, speed, acceleration, etc...

<comment><USER9> 1\. Yeah space so nothing disturbs the photons

2\. "heart of their satellite is a crystal that produces pairs of entangled photons" (see [https://en.wikipedia.org/wiki/Spontaneous_parametric_down- co...](https://en.wikipedia.org/wiki/Spontaneous_parametric_down-conversion))

3\. Mostly polarization

</comment></comment><comment><USER10> Wonderful achievement, kudos to Chinese scientists and engineers who pioneering this breakthrough.

</comment><comment><USER11> What about the interference from the trisolarians?

</comment><comment><USER12> Does speed of communicate with entangled photons travel faster than speed of light?

For example if we have the device that encode/decode voice with entangled photons and put that on Moon, Mars, does that form of communication has any delay like normal electronic communication would?

<comment><USER13> No, it doesn't see the No Communication theorem. [https://en.wikipedia.org/wiki/No- communication_theorem](https://en.wikipedia.org/wiki/No-communication_theorem)

</comment></comment><comment><USER14> Could these satellites have any implications for Facebook's drone and Google's Loon internet connectivity projects?

</comment><comment><USER15> deploy GFW is the next step

</comment><comment><USER16> The original Nature article is here: [http://www.nature.com/news/chinese- satellite-is-one-giant-st...](http://www.nature.com/news/chinese-satellite-is- one-giant-step-for-the-quantum-internet-1.20329)

This is a reprint.

<comment><USER17> Thanks, we updated the link from [http://www.scientificamerican.com/article/chinese- satellite-...](http://www.scientificamerican.com/article/chinese-satellite-is- one-giant-step-for-the-quantum-internet/), which pointed to this.

</comment></comment><comment><USER18> This is a transparent attempt to develop a military communication system that bipassses US suvalience.

</comment><comment><USER19> Does Chinese have "Golden Eye"</comment>


Ask HN: Any startups looking to hire a remote full-stack Rails dev? - <AUTHOR> I'm looking for a remote/contract Rails gig for around 20-35 hours a week.
Something where I put in 35 hours a week, and for a couple days a week, incubate ideas and work on my products.
Have a really good understanding of Ruby, Rails, OOP Concepts, and building scalable web applications. Been coding in Ruby for around 5 years.
My writings:
Integration and Unit Tests with TDD in Ruby on Rails: https://dev.to/arjunrajkumar/integration-unit-tests-with-tdd-in-rails-3230
Using ShapeUp to build a Shopify App: https://medium.com/@ArjunRajkumar/using-shape-up-to-build-a-shopify-app-bf913408af9
Gist: https://gist.github.com/arjunrajkumar/79dc37c2b20a15ee890bda4fcbfd496d
My product(s): https://apps.shopify.com/boostctr
My freelancing website: https://www.arjunrajkumar.in
LinkedIn: https://www.linkedin.com/in/arjunrajkumar007
GitHub: https://www.github.com/arjunrajkumar
Twitter: https://mobile.twitter.com/ArjunRajkumar
Email - arjunrajkumars (at) gmail
Thanks
Arjun <comment><USER2> I think what you are looking for is either the monthly "Who's hiring" thread and/or the "Jobs" tab on top.</comment>


Ask HN: Enterprise-focused CSS frameworks or component libraries? - <AUTHOR> I'm curious what everyone is using as far as internal-facing CSS frameworks?
I gravitate towards Bootstrap for most of my projects as it's so darn easy to whip up something that looks decent in a short amount of time, but on the flipside I'm starting to feel that if I have to look at another Bootstrap site my eyes are going to start bleeding.
I found, and like, Project Clarity[0] from VMWare, however it's mostly focused on an Angular use-case whereas I would like something more JS framework-agnostic.
[0] https://clarity.design/ <comment><USER2> Recently I've been using Bulma for pretty much all internal projects. Offers enough flexibility to generate any interface you need. If I need something a little more prettier I'll drop in Material Design Lite ([https://getmdl.io](https://getmdl.io)) instead.</comment>


Ask HN: Why aren't there more centralized app repo's for Win/osx? - <AUTHOR>

While I still am a huge fan of Linux and would love to go back to Linux, I've been using OS-X primarily for work. The one thing which greatly saddens me and makes me worry for the future is the lack of an open and centralized place (controlled by the user) to manage, install, find, update, and delete apps just like Linux has with pacman (Arch) or apt-get (Debian).
OS-X has the App store, but that's Apple controlled and limited.
Windows has ... ? I haven't been in windows lately so I don't know what it is. But at least windows has the Add/Remove programs panel!
So, why aren't there any real public tools such as apt/pac/yum (whatever) for Mac/Windows?
It seems like a single central point of search and control would make life a lot simpler (with the possible addition of certain UI elements, ect ect...).
Is there even anything like that around? <comment><USER2> What about Homebrew? <http://mxcl.github.com/homebrew/>

I have found it very effective for deploying basic web stacks locally. Others like <http://www.macports.org/>.

<comment><USER3> I agree homebrew is great for installing web stacks, but I am guessing they may be asking about repos for less technical software.</comment></comment>


Ask HN: Exercise Price For Options At A Startup - <AUTHOR>

I am considering joining a startup and would appreciate if someone could tell me if I am getting a good deal in terms of stock options.
First a bit of back ground: The start up is related to my PhD research area and gives me a chance to build up on my back ground as opposed to a standard industry job. So, I am considering this seriously.
The company has 1 million stock outstanding with a stock value of ~60$ per share at a recent valuation. The CEO is the majority stock holder in the company ~60%.
I am being offered around 7500 stock options with the strike price at the fair market value (~60$/share). Since the strike price is so high,  it basically makes it impossible for me to exercise the options without selling the stock at the same time (when the stock is vested).
Is the strike price for the options normally equal to the current market value or is it usually a discounted price ?
Thanks ! <comment><AUTHOR> Thanks for your replies everyone ! One of my concerns was that CEO has been putting in all the money so far, so the valuation of the company is questionable.

Only comparison I could make was with another competitor in the same area, which is valued about twice of this company. So, the valuation doesn't look too arbitrary.

The good thing is that the CEO has been the CEO of another big company for >10 years. So he is capable of making this company a success. This company has been around for 5 years and has some physical products out there, so the chance of it going belly up over a short period is relatively low.

They are offering a salary that slightly exceeds that job current job including bonus/401K etc. and the vesting period for the options is 3 years with 1/3rd of the options vesting each year.

The CEO wants to make the company profitable and keep it private if possible. He said I could sell the options back to the company once they vest. He said he just converted somebody's options to company's stock once they vested. I am not sure if I can get real cash for the options though, if the company is still private and not seeking funding.

The offer letter says vesting period, but it doesn't give details regarding what happens if the company gets acquired before my options vest.

Is it okay to ask for the options agreement, before joining the company ?

</comment><comment><USER2> I think this is a case where it's probably best to look at regular compensation and take stock options out of the evaluation. A high strike price and a majority owner who wants to keep the company private mean that there is low likelihood for a significant upside.

After a year you will need to come up with $180,000 to exercise your options. That's real money for a small ownership stake with no control - i.e. it would pave a substantial runway with ramen for your own startup. Sure, if the stock is up above the strike price, you could borrow and then sell for a profit - but that's likely to be in the annual bonus range (a few thousands) rather than home run money.

Two additional pieces of advice: make sure that you understand the tax implications, and be sure to read over any buy/sell agreement carefully.

Good Luck.

<comment><AUTHOR> Thanks brudgers ! Is it okay to ask for the stock option agreement before joining the company ?

<comment><USER2> Based on not having done so myself in my younger days, I would absolutely require it (in regards to a closely held corporation).

It is not uncommon for the stockholder agreement of a closely held company to require the sale of shares back to the company upon an employee's departure or to prevent the sale of shares to a person of the employee's choosing.

In particular for your case, the agreement will tell you whether the company is obligated to loan you money in order that you may exercise your options so that the stock may be resold back to the company.

The more I have thought about it, the more this looks like a discretionary bonus not really an investment opportunity. The amount of money entailed to exercise your options and retain the stock is just too high - these are option grants which are vesting not stock grants. If at the end of the first year the company doesn't loan you money to exercise your options, there's no value for you unless you have $150k in cash handy.

I would add that 7500 shares is going to require a ten billion dollar exit to give you "fuck you" money (assuming no dilution or liquidity preference). Again it's probably best to ignore the stock as a form of compensation.

[edit] Any resistance to giving you the stockholder paperwork while you are considering the offer is, in my opinion, a red flag.

</comment></comment></comment><comment><USER3> "at a recent valuation"- is that market imposed or internal to the company? Finding one investor bold enough to put in at a $60 basis is completely different from publicly trading at a $60 basis.

After the company goes through $XX million of funding, gets closer to its goal, but the industry and stock market don't value it, you may have singlehandedly helped it go to $45 instead of $0.01, but you don't make out, period.

My understanding is that you can sometimes sell the option for fair market price once it vests (again, publicly traded at that point?), so worrying about how high the strike price is is the least of your problems with this deal.

These deals often have "vest at the board of directors' discretion", "fire before vesting" and dilution gotchas that leave you holding the bag (an empty bag) when it's time to pay you. Keep a close eye on those.

The reason to issue options at market value is to avoid you getting a tax bill right away (for income you don't get to spend). If you do take the deal, be sure you file the correct tax form immediately to keep that tax liability away.

Hopefully this is a great position with great salary, because at $60 this company's mature enough that without a major breakout and savvy business CEO, the options are lottery tickets.

</comment><comment><USER4> Seems normal--whether it's a good deal or not depends on where that valuation comes from (in-house or pegged to a funding round), where you think the company will exit, if you think the company will exit, the salary they're offering, and the salary you could get elsewhere.

If they sell for a penny under $60 million, your options are underwater and worthless. If they double in value over the next 4 years (assuming standard vest), that's $450k to you if they sell for $120 million. If they never exit and you leave the company, you're basically screwed (unless you have $450k lying around and are certain it will be liquid again later).

You should make a projection of how you think the company's value will change and weigh that against the salary they're offering. Three-quarters of a percent sounds pretty generous for a startup that's already valued at $60mm, unless you're coming in at a pretty senior level, but without knowing where that valuation comes from it's hard to say for sure.

</comment><comment><USER3> Since you've mentioned the founder is the source of the $60 valuation, you need to look at the fundamentals of the company to calculate what those options are really worth. (who's the other 40%?)

Figure how many $M in earnings the business has now, 1 year, 5 years, and then multiply that by a P/E ratio, of, say, 20. If you're nowhere near $60M then the founder is not being honest with you (and unfortunately, probably not honest with himself either).

</comment><comment><USER5> Usually current market value. It's discounted if it's considered high risk (and therefore has the possibility to tank).

<comment><USER5> Can you confirm whether you can definitely exercise the sell? Also, what is the length of the term of vesting? Taking that into consideration; do you see this company around at that time?</comment></comment>


Gender guesser by name - <AUTHOR> http://www.gpeters.com/names/baby-names.php

<comment><USER2> Seems to be getting slashdotted now by HN users trying it out. Some of the results look quite odd.

<comment><AUTHOR> Really? Which names' results seem odd?

I came upon it when I needed to guess the gender of some contacts we selected to send marketing postcards to.</comment></comment>


Ask HN: Can the Play! framework become Rails for Java? - <AUTHOR>

I'm a CS student at the University of Edinburgh.
I have to use a lot of Java, C, Python and sometimes even Haskell. I have to use PHP at work.
I would love to spend more time learning ruby and rails. I just find my time would be better spent increasing my skills with tools I actually need to use daily as i'd only use RoR for my side project web apps.
Do you think the play! framework for java is a good alternative to rails or will it never become as popular?
http://www.playframework.org <comment><USER2> I would second the 'Grails' comment. Groovy has similar expressiveness to Ruby's, but retains much Java-ness needed for Java people to make the leap. You can use quite a bit of Java knowledge and experience in Grails, while gaining a lot of productivity.

</comment><comment><USER3> Part of what makes Rails so popular is Ruby itself, and this is not by accident. Although Play! may implement many of the features of Rails, the expressiveness of Ruby is what makes Rails tick.

Just my 2 cents.

</comment><comment><USER4> Grails and JRuby on Rails are already Rails for Java, and there are a ton of existing frameworks out there in Java for anything you can think of almost, so no, I doubt it.</comment>


Ask HN: Open-source equivalent to Ink File Picker? - <AUTHOR>

I'm starting a new project and I'd love to use Ink file picker (https://inkfilepicker.com) but they're charging (IMO) a ridiculous price for their basic package ($19/mo) and the prices after you exceed the quotas are also very high.
I was wondering if there was an open-source equivalent. I know about basic file uploaders (like jQuery File Upload, etc..) but they only have awesome support for uploads from desktops, and I think the integration ideas that Ink has come up with are really neat (just not monthly pricing sort of neat).
Also, if there is anyone interested in doing a Kickstarter for something like this, I'd be willing to contribute $100 or so, and I would imagine a large amount of people would too. <comment><USER2> It depends entirely on what you need.

Here are some alternatives for client side:

[https://github.com/blueimp/jQuery-File- Upload](https://github.com/blueimp/jQuery-File-Upload)

[http://www.plupload.com/](http://www.plupload.com/)

Given that under normal circumstances that development time is expensive, you'll save a lot of money even if you have to pay $29+ a month.

</comment><comment><USER3> Hi Ian,

Cormac here from Filepicker - can you please email email@example.com and we can discuss your needs?

Thanks, Cormac</comment>


Bootstrap theme to make sites look like they're from the 80s - <AUTHOR> https://github.com/kristopolous/BOOTSTRA.386

<comment><USER2> This is amazing. So convincing that I was trying to use it with only a keyboard for a good half minute before it clicked it was still a website.

Allow full-keyboard navigation and restart the DOS revolution?

</comment><comment><USER3> Nicely done. This made me nostalgic.

</comment><comment><USER4> Haha, that is amazing! Nice work!

</comment><comment><USER5> This is awesome.

</comment><comment><USER6> any demo-site available?

<comment><USER7> Yes: [http://9ol.es/BOOTSTRA.386/](http://9ol.es/BOOTSTRA.386/)

<comment><USER6> downlaod -> [http://9ol.es/BOOTSTRA.386/assets/bootstrap.zip](http://9ol.es/BOOTSTRA.386/assets/bootstrap.zip) -> 404

<comment><USER7> It looks like they just cloned the bootstrap website and changed the theme. They probably don't include bootstrap.zip because this is just a demo, and they wouldn't have the bandwidth to distribute all of bootstrap as a zip file.</comment></comment></comment></comment>