Parsing short hexadecimal strings efficiently - <AUTHOR> https://lemire.me/blog/2019/04/17/parsing-short-hexadecimal-strings-efficiently/ <comment><USER2> You can use the "fancy math" version on all 8 bytes in the string simultaneously:

        #include <cstdint>

        uint32_t convert_hex(const char* s)
        {
          uint64_t a = *reinterpret_cast<const uint64_t*>(s);
          a =          (a & 0x0F0F0F0F0F0F0F0Fu) + 9 * ((a & 0xc0c0c0c0c0c0c0c0) >> 6);
          a =          (a & 0x000F000F000F000Fu) |     ((a & 0x0F000F000F000F00) >> 4);
          a =          (a & 0x000000FF000000FFu) |     ((a & 0x00FF000000FF0000) >> 8);
          uint32_t b = (a & 0x000000000000FFFFu) |     ((a & 0x0000FFFF00000000) >> 16);
          b = __builtin_bswap32(b);
          b = (b & 0x0f0f0f0f) << 4 | (b & 0xf0f0f0f0) >> 4;
          return b;
        }

Compiles to 30 instructions with clang, so 3.75 instructions per byte. (clang is one instruction cleverer than gcc) No branching, the only "complicated" instructions are bswap (__builtin_bswap32) lea, (the "multiplication" by nine) and one addition. Other than that it's all bit manipulations. (moves, shifts, ands, ors) However, I doubt it will pipeline well, the data dependencies are quite linear.

It has _very_ little tolerance for inputs that are anything other than 8 byte hex strings. Do error checking elsewhere.

I doubt this would be faster in any meaningful sense in a real world use case.

</comment><comment><USER3> Using of array lookup is a bad wayof optimization: digittoval[src[N]] can take up to 200 cycles if not in cache

Only synthetic tests that small enough (most of them do nothing than tested code) show good results.

<comment><USER4> The only reason that you'd want to optimize this function is if it's called frequently. Imagine you you have a text file or database with millions of numbers in ASCII hexadecimal notation. When parsing that data with this code, the table is practically guaranteed to be in the cache.

Modern processors have 32 KB in L1 just 4 cycles away, hundreds of kB in L2 12 cycles away, and MB of L3 on-die cache which still only takes 50 cycles or so. I'd trust the machine to be certain to put this 256 byte table in L1. It would probably even pull the relevant parts (48-57 for the decimal digits and 65-70 for alphabetic) of a 65 KB 2-entry table if you were calling it in a tight loop. I'm curious if you could load it fast enough to sort out cache when working with a 4-entry, 4 GB table...

<comment><USER3> >Imagine you you have a text file or database with millions of numbers in ASCII hexadecimal notation

These much amount of data with guarantee will crowd out this array from cache bcauz processor cache in not a LRU

<comment><USER3> And now imaging an Operation System with hundreds or even thousands other processes at work.

</comment></comment></comment></comment><comment><USER5> The current winner is a SIMD-ish solution using 32 bit math as 4 8-bit lanes. This has been added to the repo, and is discussed in the comments.

[https://github.com/lemire/Code-used-on-Daniel-Lemire-s- blog/...](https://github.com/lemire/Code-used-on-Daniel-Lemire-s- blog/tree/master/2019/04/17)

</comment><comment><USER6> I don't have the spare cycles to test this out for myself right now, but I'm curious if a 64kb table would be substantially faster. You'd cut it down from 8 indirections, 3 shifts, and 3 ORs to 4 indirections, 1 shift, and 1 OR.

        uint32_t hex_to_u32_lookup(const uint8_t *src) {
         uint16_t *wsrc = (uint16_t *) src;
         uint32_t v1 = digittoval[wsrc[0]];
         uint32_t v2 = digittoval[wsrc[1]];
         return v2 << 8 | v1;
        }

(Also, small note: The function is named `hex_to_u32_lookup` but it only gives a 16-bit result. Might want to clarify in the post.)

<comment><USER7> One comment in the article pointed out that you could create a 4GB lookup table, and convert 32 bits of input at once. This is actually less silly than might otherwise seem, because only 64KB of it would ever be read for correct input; the table itself would only exist as a reservation somewhere in the process' 64-bit (well, 48-bit actually, but still) virtual address space, so a lookup of invalid input could easily be made to error out and return some error condition.

For that matter, I'd want to run the author's "fancy math-based function" through a superoptimizer and check that there isn't something that can do the job in fewer cycles.

<comment><USER8> Wouldn't the 'valid' values in such a table be relatively sparse, creating a high likelihood of cache misses? The guy's agonizing over 4 cycles, but a cache miss is far more costly.

</comment></comment></comment><comment><USER9> With modern hardware, for this to be a meaningful percentage of your workload, you'd need to be working with super high data volumes (100 megabytes per second at the very least, maybe an order of magnitude more depending on the exact hardware).

A reasonable system designer would never create an interface that accepts only hexadecimal input for bulk data transfers at those rates. That would waste half the I/O, which makes no sense!

In this case, the problem with your system isn't the cycle count of your hex conversion function. It's a poorly designed interface that's forced to use hex for high data volumes. You get maybe a fraction of a percent optimizing the hex conversion function, but there's a low-hanging 100% improvement if you just use all 8 bits of your bytes.

Or in Donald Knuth's words, "Premature optimization is the root of all evil."

<comment><USER10> Oftentimes the biggest data-ingestion tasks happen at organizational boundaries. You find this great open-source data set that's 77TB, or you contract with another company to dump a 50GB CSV file on your FTP server every night, or you pay for API access to a feed that generates 1G/sec, or another department dumps 1TB in your S3 bucket nightly.

There's a strong incentive to use standardized text-based formats (particularly JSON and CSV) for these. You can inspect sample data with a text editor, or just with 'head'. You can run really simply data analytics with just UNIX tools (I've found that a 'gunzip -c | grep | awk | grep | wc' pipeline has gotten me results in 15 seconds that would've taken 5 minutes with Python or half an hour in Java). Everybody already has a well-tested parser and serializer for the format in any language they might choose to use. Everybody's already familiar with them; you need only document field types & formats rather than giving a byte-by-byte description of the protocol. With JSON in particular, you've got 1-line parsing built into the browser instead of needing to ship a large library. If problems arise, you can dump the raw input record to the console for debugging without needing to pore over a hex dump, and you have tools available (jq, awk) for filtering out extraneous information.

If you control both sides of the protocol, than by all means use an efficient binary serialization protocol like Cap'n'Proto. But a lot of interesting data ingestion problems don't fit in this category. Oftentimes the system designer doesn't actually have control of the format that data is provided to the system.</comment></comment>


Cost of Hiring Full-Time vs. Freelance Software Developers - <AUTHOR> https://www.codementor.io/codementorx/cost-of-hiring-full-time-and-freelance-software-developers-59trf8m1z <comment><USER2> Hiring a full time employee is an investment to the company. However a Freelance Developer is not they are there for short term or small projects. This article fails to mention this an only goes over the numbers. There is no way to quantify the value of a full time employee knowledge and experience within the company</comment>


Ask HN: Best Embeddable Feedback Collection Web App? - <AUTHOR>

What services are you all using to collect feedback in your apps?
I checked out Get Satisfaction, but it seems like overkill to start with. Wondering if there is something a bit more minimalist.
Thanks in advance, ladies and gents. <comment><USER2> We built something in-house (Rails), and have been thinking about spinning it out into a minimalist feedback app. I'd be happy to share the code with you if you give me feedback on it. firstname.lastname@example.com

Regarding currently-available services, I've also used KISSInsights and Olark. Both are useful, and are ready to go right now. I'd check them out, but recognize that they have a fairly specific focus (not a bad thing; just might not work for you). KISSInsights is like a really minimal survey. It's really great for that. I believe they have an option where users can give you open- ended feedback, but I don't know if that's in the free account. Worth checking out. Olark is good, too, but I've found it's only useful for synchronous interactions. If I don't actively engage with people on it, it doesn't yield any substantive feedback.

All that being said, check them out.

</comment><comment><USER3> You might take a look at Kiss Insights. Theirs is a very simple, elegant embedded solution to on page surveys. <http://www.kissinsights.com/>

Also, I believe Monyta does a similar service to Get Satisfaction, but their site seems to be down right now.

<comment><AUTHOR> Interesting.

As I explore, prompting seems > open ended for feedback. Thanks for the suggestion.

</comment></comment><comment><USER4> I've added feedback via uservoice.com for a recent project. Their free tier is pretty usable.</comment>


Making sexy molecules in PowerPoint - <AUTHOR> http://www.chemistry-blog.com/2015/06/17/making-sexy-molecules-in-powerpoint/

<comment><USER2> "it only takes seconds to make high-quality molecules"

I have a hard time accepting that this is true for any but the simplest of molecules. Takes caffeine or Diazepam as more realistic examples. These have double bonds, which are drawn offset from the center-to-center line, and use elements besides carbon, which need either labels or CPK color assignments.

Even in the case shown here, benzene should be drawn with double bonds for correct Kekule interpretation, or with one of several ways to denote aromatic bonds. However, there are fields like macromolecular structure visualization where bond type information is often omitted, so this is not critical. But drawing cyclohexane would be difficult because of the non-planar hydrogens.

There are any number of tools for making eye-catching images. These include programs that will render the atoms and bonds using more complex materials, and including shading effects, fog effects, and multiple light sources. I think it would be better to leave this PP example in the "neat though very limited applicability" category.

</comment><comment><USER3> I saw a PowerPoint slide presentation recently demonstrating how electrons form different kind of bonds in molecules, with the orbits of each electron modeled by hand in powerpoint and animated...including custom paths for the valence electrons.

Among all the atoms in the molecule, there were dozens of electrons whipping around the slide in perfect loops, it was kind of breathtaking to think somebody spent likely weeks putting that slide together.

<comment><USER4> I always wondered why presentation packages like PowerPoint and Keynote do not expose a scripting API to allow one to programmatically keyframe animations and such. That would make these sorts of effects almost trivial to achieve.

<comment><USER5> VBA?

</comment></comment></comment><comment><USER6> Readers interested in chemistry modeling software solutions may want to go beyond the capabilities of PowerPoint to a specialized program for chemistry modeling. The program I know best, Bitwixt,[1] has been refined over more than a decade and is a very interesting educational tool.

[1] [http://www.bitwixt.com/jsite/](http://www.bitwixt.com/jsite/)

<comment><USER7> I'd like to recommend Avogadro which is FOSS. One can drag and drop atoms to create any molecule. With annealing the atoms the will arrange themselves in a physically realistic position.

[https://avogadro.cc](https://avogadro.cc) [https://avogadro.cc/wiki/Screenshots](https://avogadro.cc/wiki/Screenshots)

Here's a screencast of building a caffeine molecule with Avogadro: [https://www.youtube.com/watch?v=HrbahnykY6g](https://www.youtube.com/watch?v=HrbahnykY6g)

</comment></comment><comment><USER8> So no one will mention the Clasp (Lisp on LLVM developer)? He built a language to build better, albeit not visualize, better molecules.

If you are on this article, you probably will love to watch this guy. I am computer nerd and this guy makes me want to go back and study chemistry.

[https://www.youtube.com/watch?v=8X69_42Mj-g](https://www.youtube.com/watch?v=8X69_42Mj-g)

<comment><USER2> I just watched it. I heard pretty much the same aspirations since the 1980s. See [https://www.fourmilab.ch/autofile/www/section2_82_2.html](https://www.fourmilab.ch/autofile/www/section2_82_2.html) for when AutoDesk looked at entering this field.

At 15:56 the speaker says "Synthetic chemists normally they design things with plastic model sets."

This just isn't true, and hasn't been for a very long time. At 17:54 he even says there's GUI-based software now to design molecules. That's what most chemists use.

My experience is that it doesn't take 20 minutes to draw a molecule using the current generation of tools. In fact, you can try it now - go to [http://web.chemdoodle.com/demos/sketcher](http://web.chemdoodle.com/demos/sketcher) or [https://pubchem.ncbi.nlm.nih.gov/edit2/index.html](https://pubchem.ncbi.nlm.nih.gov/edit2/index.html) or [http://scitouch.net/ketcher- demo/ketcher.html](http://scitouch.net/ketcher-demo/ketcher.html) and draw one yourself. (This is for small molecule chemistry. For large molecule chemistry, there are other tools and other issues to worry about.)

In minute 23 he talks about computing the second derivative of the force fields, and how complex it is. Thing is, my co-worker did that manually when he wrote the original NAMD implementation. (NAMD is a molecular dynamic program.) So it's not something that's all that hard to compute. It's just tedious. (And his code is 10% slower than the hand-written code, so he knows that people do this sort of thing manually.)

While it's useful to have automatic code generators if you want to add new force fields often, we just don't do it all that often, because parameterizing the force field is the hard problem, not computing the second derivative.

At 31:25 he says that SciPy is only really possible because of Boost.Python. This isn't true. I just downloaded scipy-0.16.0b2 and verified that it does not use Boost.Python. ("ag -i BOOST_PYTHON_MODULE" finds no matches.)

At 49:30 he talks about a technique that sounds like pharmacophore models, which have been around since at least the 1990s. There are tools that will build molecules to fit pharmacophore models.

What I didn't see was anything about dealing with waters, and counter-ions, toxicity, or AMDE (absorption, distribution, metabolism, and excretion) issues.

I didn't hear anything which required multiple years of tool building ("yak shaving") to get to what he wanted. Every technique he mentioned is something that people have been doing already, in C/C++/Python.

<comment><USER9> scipy uses cython (previously swig). It is correct that its performance depends on C and Fortran code (but you knew that).

Are you sure your coworker found the derivates for the force field? They were already published when VMD was written.

I think you're trying to quibble with some of his minor points. Schaf's quite aware of water and counterions (we used to work in the same room at UCSF when he was writing AMBER's LEaP tool that adds water and counterions to molecules).

<comment><USER2> The speaker said that SciPy uses Boost Python. My comment here was that it does not. I said nothing about SciPy's performance.

I didn't say that my co-worker was the first to compute the derivatives. I said that it wasn't that complex of a task. Mark Nelson worked out by hand the second derivatives for the force fields and implemented them in NAMD (note: NAMD is not VMD). He also checked it against a couple of other implementations, including the one in XPLOR. I think he also checked against PMD and YAMD, and I believe he noticed that the PMD implementation was copied from XPLOR.

My point is that it's not hard to find these manually. In any case there's little need to figure it out from scratch since nowadays the force-fields are available in code with a permissive license, and the math available in publications like [https://books.google.com/books?id=GYTuCAAAQBAJ&pg=PA168&lpg=...](https://books.google.com/books?id=GYTuCAAAQBAJ&pg=PA168&lpg=PA168&dq=automatic+differentiation+%22force+field%22&source=bl&ots=G61DuaDKJw&sig=ho9GFl30kOUoqCrej8HXUXHzSDI&hl=sv&sa=X&ei=XYCJVcrML8LlywPWvLrAAQ&ved=0CC0Q6AEwAQ#v=onepage&q=automatic%20differentiation%20%22force%20field%22&f=false) .

It can make sense to develop new tooling to generate code automatically. The result might be faster than manual code, but as we heard, the auto-generated code is currently 10% slower than manual code. Or it might make sense when developing many different types of force fields, like what Konrad Hinsen does in ScientificPython (see [http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.97....](http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.97.9462&rep=rep1&type=pdf) ). However, I heard nothing about developing new force fields, and in any case, parameterization is the limiting factor, not computing the second derivatives.

My 'quibbles' are two-fold. The major one is that I heard or read 30+ years of history on how molecular modeling can be used to design solutions to real- world problems. The 1980s thought that it would be a CAD problem (which it wasn't). The late 1990s thought it was a simple matter of nanotech, with all sorts of designs for nifty diamond-based structures with no real-world hope. We've had special purpose programming languages for molecular modeling, custom computers with specialized networks, custom designed chips, GPU-based implementations, and more.

There's no evidence that the limitation is in the tooling, which is a major part of the speaker's thesis.

The minor one is that if someone makes minor mistakes that end up placing the speaker in a brighter light, and says them with confidence, then I believe it's reasonable to discount more the major points said with confidence which have less evidence, and which also place the speaker in a brighter light. What you see as quibbles for minor points I see as a way to judge how strongly the speaker is willing to trust personal beliefs over evidence and proof. (Yes, those personal beliefs might be right, but that's my previous point.)

</comment></comment></comment></comment><comment><USER9> Why in the world would you do this in PowerPoint.

Get PyMol. render it using povray.

<comment><USER10> We use VMD, son, but they use Pymol.

<comment><USER2> Start up VMD and see my name in the credits. :)

</comment></comment></comment><comment><USER11> Sounds to me like they would rather want to use something specialized like this.

[http://web.chemdoodle.com/demos/3d-editor](http://web.chemdoodle.com/demos/3d-editor)

Please people. Don't do stuff like this in word or powerpoint.

</comment><comment><USER12> The result is good, but it seems like more effort than necessary and using drawing objects in Office is always a recipe for compatibility problems if you use any other program (e.g. Libreoffice or the the web version of Office).

<comment><USER13> Agreed, the time invested to learn how to make objects such as shown in Powerpoint would be better spent learning to use Illustrator or Gimp. The results would be much more useable across different media as well.

<comment><USER14> That being said, there are good uses of presentation software outside the norm, as in these motion graphics: [http://www.lindadong.com/blog/keynotemotiongraphic](http://www.lindadong.com/blog/keynotemotiongraphic)

<comment><USER13> Agreed. What you linked to looks like an interesting way to generate simple animations, which indeed could be of wide interest. I haven't (yet) tried using it, but may...

</comment></comment></comment></comment><comment><USER15> Should have carried #overlyhonestmethods label

</comment><comment><USER16> "When all you have is a hammer..."

</comment><comment><USER17> "This is just too sexy for PowerPoint" \- D. Bryne

</comment><comment><USER18> I'm surprised there isn't a latex package that can do this (that you could then use w/ Beamer.)

<comment><USER19> I think TikZ is fairly capable in this regard, I never used it for 3D stuff though.

[http://www.texample.net/tikz/examples/tag/3d/](http://www.texample.net/tikz/examples/tag/3d/)</comment></comment>


Amazon Removed Anti-Vax Documentaries from Prime Video - <AUTHOR> https://www.buzzfeednews.com/article/carolineodonovan/amazon-removes-anti-vaccine-videos <comment><USER2> Unpopular opinion: I don't like this. Would much prefer that ideas compete. Id sort of give Amazon a pass since, unlike twitter, Reddit, Facebook & YouTube, it doesn't make many promises regarding the free exchange of ideas. But still.

<comment><USER3> To me, this action says "We have chosen not to publish material, that is based on indisputably false premises, that may harm viewers and the public at large."

That sounds like an acceptable line to me.

<comment><USER4> But is that true? Did they remove all videos based on false premises? And how did they decide the premise was false?

<comment><USER5> They need not decide the premise is false; they can rely on scientific consensus. It's not a perfect heuristic but it's the most useful one we have. If they're transparent about the sources they use and they're impartial and consistent in their application (read: no videos given special treatment), they're not arbitrating. They're (actively) reporting.

<comment><USER2> Arguable that sugar is more harmful than a video.

<comment><USER5> It sure is! Tell you what, I'm all on board for a massive awareness campaign by Google, Amazon, Apple, Facebook and Netflix on the dangers of sugar intake as well.

<comment><USER6> That's like the tobacco industry advertising the dangers of skin cancer.

Sure, good, I guess, but I'm left very confused.

</comment></comment></comment></comment></comment></comment></comment><comment><USER6> It would be better to leave them up but force a disclaimer to scroll along the bottom the entire doco proclaiming factless and fictional in nature.

I don't think hiding from these issues is the appropriate response.

Nor is pouring gasoline on the fire fueling these conspiracy theories.

<comment><USER2> Isn't there an in-between of doing nothing? Asking Amazon to publish an opinion is a pretty big ask. At least deleting the item doesn't necessarily imply a position.

<comment><USER5> _> Asking Amazon to publish an opinion is a pretty big ask._

It's not an opinion.

</comment></comment></comment><comment><USER5> Fantastic. I would be thrilled to see other tech companies declare a holy war against this kind of misinformation. In fact, it would make me ecstatic if they started doing the same with other topics that have overwhelming scientific consensus, like climate change.

I frankly don't care if it's censorship. It's a hill I'll happily die on.

<comment><USER7> Phlogiston, luminiferous aether, and Newtonian mechanics also once had "overwhelming scientific consensus".

" _The ends do not justify the means._ " Even for something as important as addressing climate change.

<comment><USER5> Are you implying classical mechanics is comparable to the anti-vaccination movement? Are you aware we've successfully landed people on the Moon using calculations derived by classical mechanics? That example has harmed your argument, not supported it. Just because we have quantum mechanics doesn't mean we can't make true statements about the world using Newtonian mechanics.

As for phlogiston and luminiferous aether - yes, science is not omniscient. But those hypotheses are attributable to insufficiently precise instruments and knowledge.

More importantly, they were _positive_ statements about the world. You're comparing them to the demand for evidence that vaccinations are harmful, to which the best rebuttal is a counter-demand to prove a negative (that they're _not_ harmful).

What else you got?

<comment><USER7> > _Just because we have quantum mechanics doesn 't mean we can't make true > statements about the world using Newtonian mechanics._

True statements? A scientist would acknowledge them as adequate approximations, not true statements.

And by the way, let's see you build GPS (relativity) or computers (QM by way of semiconductor physics) using Newtonian mechanics.

> _More importantly, they were positive statements about the world. You 're > comparing them to the demand for evidence that vaccinations are harmful, to > which the best rebuttal is a counter-demand to prove a negative (that > they're not harmful)._

That's precisely the point. Science doesn't need self-appointed police squashing silly ideas like anti-vax precisely because science makes "positive statements about the world." Repeatable results speak for themselves.

[EDIT] To clarify further, allowing squashing of ideas because they don't agree with current scientific consensus will just make Planck's lament all the worse. (" _A new scientific truth does not triumph by convincing its opponents and making them see the light, but rather because its opponents eventually die, and a new generation grows up that is familiar with it._ ")

> _What else you got?_

After that last line, a slightly lower opinion of your ability to debate in a civil fashion.

<comment><USER5> Your first sentence nitpicks the word "truth" and ignores the spirit of the point. Your second ignores my point about the validity of Newtonian mechanics and, in the process, detracts from _your own_ point about approximations instead of absolutes. It's also wrong for what it's worth - again, NASA used computers to get us on the Moon. Computers need not be digital.

I don't really care what your opinion is of my ability to debate in a civil fashion. That you are incorrect is not an opportunity for me to persuade _you_ ; your arguments are simply a vehicle for convincing the onlookers reading the back-and-forth. And to be blunt, when you're resorting to nitpicking words, ignoring points and comparing Newtonian mechanics to anti-vaccination, I also don't really care about abandoning civility.

And if I'm being honest I _do_ get a certain satisfaction from challenging your examples in such a cavalier fashion, because they're frankly silly and incomparable. Considering the stakes (compromising herd immunity, implicitly defending harmful ignorance) I am all-in on censorship and abandoning decorum.

But you're free not to debate with me if you consider me gauche or impolite, just as Amazon is free to censor all the videos on its own platform.

</comment></comment></comment></comment></comment><comment><USER8> Good

<comment><USER9> Silencing ideas is not the way to correct them...

<comment><USER10> How well has letting people air these ideas worked? Compare the number of Nazis in Germany (and hate crimes committed by same) vs. Lost Causers in the American South and their hate crimes.

It's one thing to hold a belief in a certain threshold for freedom of speech. It's another thing to state without evidence that it has better outcomes.

<comment><USER11> There's a really nice place you may consider as an option that tightly controls information. No need to worry about encountering bad ideas in the People's Republic of Korea. There's also China. They have a much safer internet there. Not as safe as DPRK's internet, but still pretty good.

<comment><USER10> And yet Germany is nothing like DPRK or PRC. Maybe there exist freedom of speech thresholds in between the extremes of Somalia (where you are free to shout "fire!" in crowded theaters) and DPRK?

It amazes me how many Americans religiously believe that their thresholds are the only ones that work and that the only other option is some ridiculous extreme. You can see the same religiosity in weapons freedoms. Somalians have more. North Koreans have less. Yet there are many working thresholds in between, most of which empirically perform better than the US's.

</comment></comment></comment></comment></comment><comment><USER12> [https://youtu.be/RJh3TiCFJH4?t=30](https://youtu.be/RJh3TiCFJH4?t=30)

</comment><comment><USER13> I wonder if they inadvertently strengthened the conspiracy theory by doing it. Sometimes censorship has that perverse effect. I easily see someone hearing from their "friend" about how Amazon has removed the video because they know it's true, and how it just validates all the bullshit claims presented there.

<comment><USER5> It's a balance. Banning books has been known to make them more widely consumed, but reading is intrinsically less viral (and more informationally dense, typically) than watching a video.

I think it's easier to attain a critical mass of followers if these kinds of _videos_ go unchallenged.

</comment></comment><comment><USER14> Amazon is starting to ban some far right books. Sexual Utopia in Power is currently banned(it's on libgen) likely as a compete blacklist on it's publisher. The author had published a book on Kojeve for an academic publisher and the book has received positive feedback from many conservatives who have nothing to do with the far right. I see no reason whatsoever for it to be banned. It may be coming back because it's page is up and not completely deleted like many other books though it's still not up for sale.

[https://www.amazon.com/Sexual-Utopia-Power-Feminist- Civiliza...](https://www.amazon.com/Sexual-Utopia-Power-Feminist-Civilization- ebook/product- reviews/B00ZTENZZ4/ref=cm_cr_dp_d_show_all_btm?ie=UTF8&reviewerType=all_reviews)</comment>


Fortnite 6.31 New Game Addiction Pushing Kids to Gamer Rehab - <AUTHOR> https://www.bloomberg.com/news/articles/2018-11-27/fortnite-addiction-prompts-parents-to-turn-to-video-game-rehab <comment><USER2> This makes about as much sense as the rock music is satanism craze of the 1980s and it's proponents are the same kind of people with the same motivations.

<comment><USER3> Only difference now is that the WHO has given this some backing. Despite the WHO putting gaming addiction into ICD-11 it's a contentious issue and experts have come out against the inclusion of it in ICD-11. But it was added anyway.

[https://www.ncbi.nlm.nih.gov/pubmed/29529886](https://www.ncbi.nlm.nih.gov/pubmed/29529886)</comment></comment>


Google AI contest results released - <AUTHOR> http://ai-contest.com/index.php

<comment><AUTHOR> Thanks to all the people that participated and I hope you had fun creating your bot.</comment>


How Tinder turns an emotionally stable adult into a lovesick teenager - <AUTHOR> https://medium.com/@JonathanDoe/tinder-turned-me-from-emotionally-stable-adult-to-lovesick-teenager-in-ten-minutes-why-dce23ab8b0c#.x9j8actdu <comment><USER2> Am I the only one who gets the vibe that the author is _not_ particularly well adjusted and is hoping that somehow this post goes viral and gets him a shot with that girl? Even the first paragraph doesn't exactly scream "emotionally stable".

I may be projecting, because that's totally something highschool-aged me would have done. But to me this reads as a transparent attempt at getting a girl's attention rather than any valuable insight about Tinder.

Edit: a word.

<comment><USER3> Hah, I was taking that angle for granted. The author almost seems to acknowledge that himself. I still found that last section of the article kind of interesting though.

<comment><USER2> An account created two hours ago has commented only in response to the two comments in this thread.

If I was a betting man... ;)

</comment></comment></comment><comment><USER4> Sexual attraction is a powerful thing. Anyone who thinks they can cleanly separate their emotions from their sex drive is kidding themselves. Tinder is bringing casual sex to people (male and female) who might not have considered it as an option before, so it's going to expose people to unexpected emotions.

<comment><USER3> Do you think the mechanism described at the end of the article is necessarily sexual though? It sounded like the thing the OP was talking about was more the exotic pressure of suddenly having something whisper in Bob's ear "Alice thinks your cute". If that is surprising information for Bob, and all Bob gets to do is send 1 or 2 texts to Alice, I can understand that Bob will get some kind of acute OCD with respect to those 1 or 2 texts. It seems rational, given their weight. Even more so if Bob is driven by his love drive and not his sex drive.

</comment></comment><comment><USER5> cringe cringe and more cringe.

I don't know Hannah, but generally women DO NOT want you telling everyone and the internet that you found her on tinder.

<comment><USER6> There are exceptions...if he's Russell Brand it's OK. But from the writing style it seems he's not the hot guy she's talking about :)</comment></comment>


Will a Dead Bank of America Intern Change Wall Street's Pledge-Class Culture? - <AUTHOR> http://nymag.com/daily/intelligencer/2013/08/bofa-intern-death-and-wall-streets-culture.html

<comment><USER2> Betteridge says no.</comment>


Show HN: Confir.io helps you find professional conferences - <AUTHOR> http://confir.io/ <comment><USER2> Thanks for posting!

I put this together in the hopes of making it easier to discover tech conferences. It's been really hard to find conferences as an attendee, and more recently as a sponsor. Hope it's helpful for others. Let me know if you have any feedback or find conferences I'm missing.

</comment><comment><USER3> Love the concept! Is there a better way to search by city rather than clicking on one in a box?

<comment><USER2> I agree -- it's on the short list for improvements. Stay tuned</comment></comment>


Show HN: Percy – A Rust and WebAssembly isomorphic virtual DOM implementation - <AUTHOR> https://github.com/chinedufn/percy <comment> nevi-me Hi chinedufn, this looks very interesting. I am at the same stage as you re. "I REALLY want to use this for everything ...".

I see you're using wasm_bindgen quite a bit, but from a cursory look at the code; I can't figure out something:

I can see how you're using wasm in the front-end, but could you please elaborate a bit more about in the backend? I presume that your backend is Rust based?

I spent last weekend porting some code from NodeJS to a wasm module. I got it sort of working on Node, but haven't tried it on the browser yet (ran out of weekend).

I'm quite optimistic about wasm [and Rust with wasm_bindgen]. I'd been thinking of writing a native add-on for Node, but the idea that I can use wasm instead is exciting.

<comment><AUTHOR> Sure!

The backend is pretty much this (messy) file - [https://github.com/chinedufn/percy/blob/master/examples/isom...](https://github.com/chinedufn/percy/blob/master/examples/isomorphic/server/src/server.rs) .

It

1\. Pulls in your application crate 2\. Initializes your app (more or less sets initial state 3\. Renders your app's virtual DOM into an HTML string 4\. Serves the HTML to the client, along with the initial state serialized into JSON in a script tag (using serde-json) 5.Also serves the WASM script and the JS that initializes the WASM

So that's your server crate. Then your client crate also pulls in your same application crate and you compile it to WebAssembly and that's what runs browser side.

Feel free to let me know if any of that was poorly explained!

<comment> nevi-me Thanks, that makes sense. I haven't built web servers with Rust as yet; so it was a bit difficult to follow the code.

<comment><USER3> This is good enough for an example, but for a "real" web server, you wouldn't do this; you'd use a framework that handles a lot of this kind of thing for you. I _think_ this code was adapted from the final chapter of the Rust book, which is mostly about learning how to write a simple thing than being production-ready.

</comment></comment></comment></comment><comment><USER4> Can someone ELI5(+) what an isomorphic virtual dom is?

<comment><USER5> An isomorphic virtual DOM is much like an inverted-index homomorphic shadow DOM, but instead of using a shadowed mapping they virtualize the original elements _themselves_.

<comment><USER4> I'm not sure if you are you are fucking with me or if i'm just ery stupid.... :(

<comment><USER6> AFAIK he's fucking with you ^^

<comment><USER7> Yup. Otherwise he's basically talking about a structure-preserving index that maps DOM elements - that are rendered outside the main document DOM tree - <USER2> a file.

And that's not really what's going on here.

</comment></comment></comment></comment></comment><comment><USER8> How does this compare to the Yew framework?

<comment><AUTHOR> Yew is awesome and just knowing that something like that was possible inspired Percy. I also looked at Yew's `html!` macro when figuring out how Percy's could / should work.

One difference is that Yew is powered by stdweb and Percy is powered by wasm- bindgen.

I'm personally SUPER bullish on wasm-bindgen because it's been designed from day 1 to be able to take advantage of the host bindings proposal when it materializes.

Host bindings tl;dr is that instead of needing to go through JS to interact with browser APIs you can interact with them directly.

Another difference is that to my knowledge Yew doesn't support server side rendering ( which was why I couldn't use it even though I wanted to :( ).

Without having used Yew I don't want to comment any further than those high level differences.

I can say that a big focus of Percy is to be a grab bag of modules / tooling for frontend Rust web apps with a major focus of you being able to swap out the parts that you think are bad for other peoples' better implementations. That dream isn't realized yet.. but I think that Rust's generics / traits could make this feel very clean!

<comment><USER9> >One difference is that Yew is powered by stdweb and Percy is powered by wasm- bindgen. >I'm personally SUPER bullish on wasm-bindgen because it's been designed from day 1 to be able to take advantage of the host bindings proposal when it materializes.

I find it funny that you mentioned that. I actually was trying out wasm- bindget/yew recently and ended up using yew because of the wasm-bindgen limitations (mostly related to using anything with generics in the type signature).

The experience will probably improve on the future, but right now yew's actor model seems like a much simpler way to encapsulate rust libraries.

</comment></comment></comment><comment><USER10> The use of the html macro is incredibly nice, no need for a special "JSX" language, it's all builting thanks to macros. I'm working on the same thing for python (using pyxl/mixt/lys and brython) and you just proved that there's interrest in that !

</comment><comment><USER11> Heads up, there's something already called Percy in the JS space. [https://percy.io](https://percy.io)

<comment><USER12> Pretty sure there's something called everything in the JS space. Thankfully this is the Rust/WASM space so all good names get to be recycled.

<comment><USER13> Damn, time to get started on React.rs. Is rQuery taken?

<comment><USER14> Not only is rQuery not taken, jQuery isn't taken either :-D

</comment></comment></comment></comment><comment><USER15> [makes side-eyes at React team to utilize webassembly]

<comment><USER16> Why? Has anyone shown this would be faster or a smaller download?

<comment><USER15> If they moved their virtual DOM (the meat of the work React does and its primary bottleneck) over to webassembly, it would almost certainly be faster. I can't really speak to the download size, though I wouldn't be surprised if that improved too.

<comment><USER17> It's worth keeping in mind that WebAssembly can't access the DOM directly; it has to call into JS in order to do that. I haven't investigated it myself but I'd wager that because of this, any performance benefits would be negligible.

WebAssembly also can't access JS object structures directly, which means that the virtual DOM would have to live in WebAssembly land in the first place, ie. anything generated by JS that you want to end up in the DOM would have to be copied over first, or rather, you want all your VDOM-generating code to be WebAssembly code as well if you want the whole thing to be efficient.

<comment><USER15> The whole point of a virtual DOM is to simulate and reconcile changes before pushing those changes to the real DOM; it would be fairly clean to do all that processing in wasm and then send the result over to JS for reification.

It's true that there would be some challenges when it comes to "sending" data to the virtual DOM; in particular, event objects could get complicated. I assumed this project has solved that problem, but I didn't read very deeply into it.

<comment><USER16> Keep in mind that WebAssembly strings are not JavaScript strings, so there is additional data conversion overhead that needs to be accounted for, versus a JavaScript implementation. And it's not just events and DOM updates. If you wanted to preserve React's render API, the input data for re-rendered DOM needs to be converted from JS before doing a diff.

With slower data conversion and faster internal calculation, it's plausible that it might overall be either slower or faster. I don't see any way to know without doing some experiments. It would certainly be more complicated.

It seems like the sort of JavaScript library where WebAssembly would be an easy win would have low API bandwidth (not much data crossing the boundary) and do a lot of expensive internal calculations. As a UI framework, React does some internal calculations but has relatively high API bandwidth.

<comment><USER3> WebAssembly doesn't have strings, so you can model them just like JS strings if you want. It really depends on what you want to do.

</comment></comment></comment></comment></comment></comment></comment><comment><USER12> Has Facebook picked up on this yet? Good thing the Web is a Web of documents.

<comment><USER3> Facebook is a Rust user, but given that this was just announced, I doubt that they're suddenly using it ;)

> Good thing the Web is a Web of documents.

That was three for three years. It's been 23 years since we've had executable code as well.

</comment></comment><comment><USER18> can you write an app in just once file and mark what can run in the client and what must only run on the server?

<comment><AUTHOR> As in an example app?

If you don't need server side rendering you can have one Rust file but you also need a JS file to initialize the WebAssembly module. So just one file isn't reasonably possible.

For a server side rendered app you need to have a cargo workspace with 3 crates (they can be in the same repo so not a huge deal).

One crate is a `cdylib` that you compile to WebAssembly to serve your app to the client. This is a light wrapper around your actual application.

One crate is your actual application.

And one crate is your server, which is also a light wrapper around your actual application.

That server side rendering structure can be found here - [https://github.com/chinedufn/percy/tree/master/examples/isom...](https://github.com/chinedufn/percy/tree/master/examples/isomorphic)

But in terms of a super minimal example without server side rendering.. I'll be working on adding one (along with updating the current example)!

<comment><USER18> what i want to see is to have all logic to be centered around features, and have a framework compile the server side and client server out of one logical piece of code, if that even makes sense.

a bit like in the old days of php when you'd have the serverside code and html rendered in their, but this time nearly everything is running on the client unless the client can't be trusted.

you could have some kind of ring system, where something can never run on the client right up to always run on client, but all in one file.

but maybe that's nasty.

<comment><USER19> ASP.NET does this, you use its components and it generates client side javascript. In a more functional way, there's another language that does this caled Opa! [http://opalang.org/](http://opalang.org/)

<comment><USER18> yes, like runat="server" kinda thing.

</comment></comment></comment></comment></comment><comment><USER20> Another good tool if you want to write front end in a great general purpose language is scalajs. It allows you to reuse the dame Scala code for backend and front end.</comment>


We just launched Mailburn – iPhone email app that turns GMail into WhatsApp - <AUTHOR> http://www.producthunt.com/posts/mailburn-3

<comment><AUTHOR> Hi guys!

Mailburn ([http://mailburn.com](http://mailburn.com)) is an iPhone email client that shows only conversations with real people and hide all the crap in messages like signatures and quotation. Also we have email tracking built in so you will get a notification when somebody opened and read your message.

This is just our first version and first step in crusade against email. Every other month we will take one completely broken piece of email and reinvent it with new interface, awesome features and business logic. Our goal is to build proper email client step by step and tailor it for the needs of heavy inbox users just like us. We will introduce crazy things like being able to close tasks in JIRA from email notification without opening JIRA itself, or present all newsletters and promotions in a feed with 1-click unsubscribe button for each. Or how about locking your inbox from cold emails so random people without intros don't bother you? Those are just some ideas that we have in our backlog, and we know that all of them are technically possible.

We are a relentless team of 6 people who are bootstrapping with 0 money in our free time, and we don't plan to stop.

It's for iPhone and Gmail only right now, sorry Android guys and IMAP/Exchange users. We can't do everything when all we have are our evenings but we will get there we promise.

Here is link on Product Hunt, we are launching bootstrap way ;) [http://www.producthunt.com/posts/mailburn-3](http://www.producthunt.com/posts/mailburn-3)

Would love to hear your feedback!</comment>


Show HN: SentiNews – first intelligence news reader - <AUTHOR> http://www.sentinews.ml <comment><USER2> The first "intelligence" news reader? You mean a news reader for classified "intelligence" material for the CIA, NSA, etc...?

Or did you mean the first "intelligent" news reader, in that it uses machine learning to figure out what articles you like and what you don't?

<comment><AUTHOR> The main idea was to avoid negative news content with the help of sentiment analysis algorithms. It detects good/bad news articles automatically. So you can read about only good things that happens in the world.</comment></comment>


GitFinder – Use Git on Mac Right from Finder - <AUTHOR> https://gitfinder.com <comment><AUTHOR> Launch promotional code: launchmegood. Valid during limited launch promotion period, 30% off. Enjoy!

</comment><comment><USER2> Nothing regarding the pricing ?

<comment><USER3> "Buy" button at the bottom of the page, $24.95.</comment></comment>


The V language now compiles itself in 0.09 seconds - <AUTHOR> https://github.com/vlang/v/wiki/The-V-language-now-compiles-itself-in-0.09-seconds <comment><USER2> Last time when V was presented in HN, it got completely ripped apart by most posters. This was probably due to the many empty promises by the creator which V simply wasn't able to deliver on. There were also hard criticisms posted by creators of other languages like Zig, wren etc.

I want to know from V's critic, where do they feel the language is right now, now that it has had some more months behind it? Do you still feel that its a lot of snake oil or do you think it is going along a good path? Not trying to push an agenda but I am genuinely curious because I have never seen such definitive opinions against a language before in HN.

I am yet to use V (waiting for the Doom demo which would be the proof of the pudding for me), but i do check its chat and github every now and then; and things seem to be going along much better now. lots of contributions, better project management and timely fixes.

Here are some of the older threads on V;

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

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

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

<comment><AUTHOR> Soon I'll actually make a post covering all these "vaporware"/scam posts and articles.

Zig's author's criticism is hard to respond to, since he claims things like "the V compiler has freetype and glfw dependencies", which is absurd:

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

Also he claimed there was no REPL, cross compiling or hot code reloading, when all these things were there:

[https://twitter.com/i/status/1137537130887077890](https://twitter.com/i/status/1137537130887077890)

[https://twitter.com/i/status/1153363259715702784](https://twitter.com/i/status/1153363259715702784)

<comment><USER3> TBH the main criticism seems not to be of the language itself, which seems like a cool and worthwhile project, but of its "marketing".

Clickbaity rhetoric like "V Language Released" with no source code and many missing features, and now "compiles itself in _stunning_ 0.09 seconds" without a rigorous dataset or accompanying list of features that said compiler supports are likely the source of the backlash.

My outsider advice, as someone who has never made a language (so, props to you for that) is to lower the hype level, and instead focus on posting news like deep-dives into design decisions and implementation stories, which people in the PL community are more likely to appreciate.

<comment><AUTHOR> What do you mean no source code?

I think 0.09s compilation is pretty cool, I worked a lot to make it happen, and I'm excited to share it.

<comment><USER3> What I mean is that when it was announced that "V Programming Language is Released", it was just binaries and no source code: [https://news.ycombinator.com/item?id=20229632](https://news.ycombinator.com/item?id=20229632)

There's nothing wrong with releasing the binaries, but a more genuine headline might've been like "V Language: Alpha Compiler Binary Preview".

And the 0.09 second compilation is really cool! But a more genuine headline would've been "I got V to compile itself in 0.09 on my computer".

If you think I'm ranting or nit-picking, so be it. But my experience in software development is that exaggeration leaves a bad taste in people's mouths, and could harm the reputation of your otherwise really interesting language project.

<comment><AUTHOR> This was posted by someone else, I never announced it. Never saw this post.

The binaries were released 2 days before the source code, which was a weird decision. I never realized literally tens of thousands were following my every move. I'd be more careful then.

<comment><USER3> That is fair.

You've piqued a lot of interest, and now a lot of people are following your every statement. I can imagine that managing those people's expectations isn't trivial.

Best of luck! Looking forward to 1.0

<comment><AUTHOR> Thanks!

</comment></comment></comment></comment></comment></comment></comment></comment><comment><USER4> How many of Dodrill's problems have they solved so far?

[https://christine.website/blog/v-vaporware-2019-06-23](https://christine.website/blog/v-vaporware-2019-06-23)

<comment><USER5> Wow... talk about a mean-spirited article!

<comment><AUTHOR> Yeah basically complaining that WIP features explicitly marked as WIP are not ready and that the first public alpha release is not stable.

Focusing on the fact that the language is written 100% in itself from the start? Nope!

Mention that it builds itself in <1 second? Nah

Graphics library, DOOM's p_enemy.c translated to p_enemy.v which can be compiled and replace p_enemy.o, safety features? No.

The language can be bootstrapped with "cc v.c" without any dependencies? Who cares!

There's a temporary one-line os.system() hack? VAPORWARE!

<comment><USER6> `p_enemy.c translated to p_enemy.v which can be compiled and replace p_enemy.o` <\- that's extremely impressive, good on you! :)

<comment><AUTHOR> Thanks.

Here's how it looks like, although it doesn't compile at the moment:

[https://github.com/vlang/doom/blob/master/p_enemy.v](https://github.com/vlang/doom/blob/master/p_enemy.v)

I have to finish this project asap.

</comment></comment></comment></comment></comment><comment><USER7> V is a pretty interesting language. I've been playing with it for the last few months, it takes a lot of the good stuff from Go with saner syntax and defaults. And compilation speed is amazing.

The big missing item so far is GC (memory management is manual). Another thing is that the language evolves constantly, so you keep having to change your own code every week or so to stay valid.

<comment><AUTHOR> Indeed, the language changes very quickly. Things will stabilize by 0.2.

The memory model is going to be similar to Rust. No GC or manual management. I'm actually working on it right now. Should have done it sooner, but it took me lots of time to do the research and chose the right model.

<comment><USER8> I'm very curious about this.

Getting the Rust compiler to handle memory correctly took years one complete refactoring of the type system, and a number of less major changes before Rust reached version 1.0. Even after that, the borrowing system has regularly been refined to become gradually more intuitive and more powerful.

Do you have precise plans for this feature? If they're written somewhere, I'm quite interested :)

<comment><USER9> Pioneering is nearly always harder, and takes more time than later developments.

</comment></comment></comment></comment><comment><USER10> That Go code on this page [0] isn't particularly idomatic (or even functional), consider something like this [1] perhaps.

[0] [https://vlang.io/compare](https://vlang.io/compare)

[1] [https://pastebin.com/raw/FsjAQvGt](https://pastebin.com/raw/FsjAQvGt)

<comment><USER11> That return err from the goroutine looks wrong, I don't think the error is ever used. log.Fatalln(err) would keep the behavior of the V code.

<comment><USER10> It'd just cause a panic and stop that particular goroutine. To properly handle it, it needs to be passed back into a results channel or something. Generally we don't intentionally cause panics in go code as a matter of style.

You can insert a `defer log.Println(err)` if you want to handle that particular error but I didn't bother.

<comment><USER11> log.Fatalln() does an os.Exit(1), it doesn't just cause that particular goroutine to stop[1]. log.Panicln() will also cause the entire program to exit unless there's a recover[2].

log.Println(err) would be better than returning err, because returning err makes people wrongly think the error is being handled somewhere, when in reality nothing is looking at the return value. Using defer for that seems a bit strange though.

[1] [https://play.golang.org/p/wwiq1bYjwVH](https://play.golang.org/p/wwiq1bYjwVH)

[2] [https://play.golang.org/p/MpzafFlBSfx](https://play.golang.org/p/MpzafFlBSfx)

</comment></comment></comment></comment><comment><USER12> V looks like a promising language. You know you have made it when there is an "awesome v" page on github. One question, why is the original `v` much smaller than the `v` compiles using itself?

      $ size v
         text    data     bss     dec     hex filename
       445817    1032     688  447537   6d431 v

      $ ./v -o v2 v.v && size v2
         text    data     bss     dec     hex filename
       651086   51000    1000  703086   aba6e v2

<comment><AUTHOR> It's built with GCC and -O2.

</comment></comment><comment><USER9> Wow, on my old i3:

        0[08:48:16] /v/v $ time ./v v.v

        real    0m0.219s
        user    0m0.153s
        sys     0m0.064s
        0[08:48:25] /v/v $

I guess it is high time to upgrade my machine...

</comment><comment><USER13> I think I might have to try v for scripting. I've been wanting a non-dynamic language for that purpose, and v having few dependencies and fast compile times might actually make it usable for that purpose.

</comment><comment><USER14> Like a contributor I can say that @amedvednikov make a big effort to make such compilation speed possible. Also I can say that language is still easy to learn while having so many features.

<comment><AUTHOR> Well I wouldn't say the language itself has many features.

Its goal is to be minimalistic, simple, readable, maintainable.

</comment></comment><comment><USER15> Pleased to read that hot reloading is a central feature!

<comment><AUTHOR> Yes, really excited about it.

Hot reloading UI:

[https://cdn.discordapp.com/attachments/592118040179507207/63...](https://cdn.discordapp.com/attachments/592118040179507207/632545652596801537/live_vig3-2019-10-12_13.46.00.gif)

Hot reloading a graphical application:

[https://twitter.com/i/status/1153363259715702784](https://twitter.com/i/status/1153363259715702784)

</comment></comment><comment><USER16> V seems pretty similar to Zig in that it tries to compete directly with C. Has anyone here used both? Which do you prefer and why?

</comment><comment><USER17> How can I use V as a scripting language? I managed to use TinyCC as a scripting language but V seems to make more sense.

I'm also interesting in C++ interop...

This language looks pretty great. Simple, fast, nicer and lean syntax.

I'm still curious why I often see "name string" intead of "string name". I guess it's easier to parse? pythonic indent would make this language perfect.

<comment><USER18> Scripting is one of V's main features[0]. Just a couple days ago, it was incorporated into the 'master' branch[1] so you can now use it.

0 - [https://vlang.io/docs#bash](https://vlang.io/docs#bash)

1 - [https://github.com/vlang/v/commit/5cd38ec91bc1919aca9f63432e...](https://github.com/vlang/v/commit/5cd38ec91bc1919aca9f63432e38aad27233d6f8)

<comment><USER17> I meant compiling and executing V from C++, calling V functions from C++, and C++ function from V.

<comment><USER9> V produces .c files, which are then compiled to .o files, like C.

Interfacing v code into a C++ app, is like interfacing with any other C library, with the addition, that you may have to write the C headers yourself (or you can cut/paste them from the produced C file).

If you want to call a C++ function from V, you have to export it from the C++ side, like you would do for a C app: extern "C" { int your_function(int x) } ... and then call it from the V side like any other C function. ([https://vlang.io/docs#calling_c](https://vlang.io/docs#calling_c))

</comment></comment></comment></comment><comment><USER19> Congratulations!

On reading the docs, I wonder if immutable variables and const globals can be merged as a concept?

I realize the consts can be fun complex 'structs', and have features that maybe immutable variables can't? -- No mutable globals is good. But still, is there a deeper reason to not merge const/immutable

</comment><comment><USER20> Can I use live reload on functions that use imported c libs?

<comment><USER21> Hmm, this gif (linked elsewhere in the thread) seems to indicate that C libs can be used in `live` code.

[https://cdn.discordapp.com/attachments/592118040179507207/63...](https://cdn.discordapp.com/attachments/592118040179507207/632545652596801537/live_vig3-2019-10-12_13.46.00.gif)

</comment></comment><comment><USER9> Amazing ... That would make [https://www.xkcd.com/303/](https://www.xkcd.com/303/) obsolete ;-) !

<comment><USER22> It's already obsolete for people who do ML work.

I remember having to wait days or even weeks for something to train while I either sit back and relax or work on the next thing to train.

<comment><USER9> And now you do not have to wait more than a few seconds, while you train them?

</comment></comment></comment><comment><USER23> Wow! Amazing!!!

</comment><comment><USER24> Many features were stolen from Golang

<comment><USER21> In the context of programming language design, "stealing" sounds like the wrong term. Every programming language is inspired by others, isn't it?</comment></comment>


Ask HN: Review my startup - Reputely (Game Mechanics Platform) - <AUTHOR> http://reputely.com

<comment><USER3> First off congrats, and well done on a nice looking and fairly clear site.

Unfortunately, your documentation link doesn't go anywhere, and that is one of the first thing i look at when looking into API's. What does it look like, and how do they do it.

I'm in the process of building a site where most of the interactions are based around game mechanics. I'm just getting into it, and hadn't really thought about using an outside API, but you've at least given me pause to think about it.

However, going after already existing sites which want to add an element of game interaction is a good market I think.

A few things on your site specifically.

I found that the cycle on the home page rotates way to quickly to absorb any of the information. I know it stops once you click on one of the buttons below, but I found the initial speed to be a bit distracting.

The screenshot in the cycle goes below the dividing line/bar and looks wrong to me.

The light blue font used in each cycle title on the light grey gradient background except the first is difficult to read. Going a bit darker would help, or just stick with white. It isn't a problem in the cycle controls though, and looks quite nice.

You have a prominent link to your blog, but no blog posts. How about something about why you decided to build the company, how you got into it, something interesting. A blank blog just doesn't say 'dedication' to me.

You quote 'Jim Miller', but don't say what his site is. If he is in fact a real person, and they're using your api, I think it would be nice to send people to his site, and if somebody can see your api in action, it helps cross the barrier of having people be the first to deploy.

A live demo would really be great, but if that is too much to ask, a video demo would be a good idea. Though people may understand something about game mechanics, actually showing what you do is very important (to me at least).

Also, your sign-up and get the whitepaper forms don't look nearly as polished as the rest of the site. I'd clean those up a bit.

my 2 cents. Best of luck

</comment><comment><USER4> Here's what I would really like to see:

\- actual api/code examples.

\- annotated screenshots, and _lots_ of them (on your analytics, customization forms, how it integrates in sites, etc)

Without enough detail, I'm bound to just skip the site and never go back. With detail, I'll investigate because I'm curious, and then I will keep it in mind for my current/next project. Developers need detail.

<comment><AUTHOR> Thanks for the advice Peter.

I completely agree. The site in it's current form is a simple MVP.

My aim is to shoot for docs that have the same level of detail as Twilio's (<http://www.twilio.com/docs/>)

</comment></comment><comment><USER5> This is obviously an MVP, but there are some key things that I deem necessary to be the prominent player in this space. You can read more about what I've written about this idea here: <http://news.ycombinator.com/item?id=1263984>

The key thing is that if a site's points/badges are left in their own island then they have a fraction of the value than if they were part of a universal system (e.g. Xbox Live's GamerScore). You may claim that this will come in time, but the problem with that is your offering is less than half as compelling without a universal system and such initial traction will be hampered. Furthermore, if you don't plan for a universal system initially you won't have the necessary policies and normalizations in place to make for a 'fair' system.

Alongside that if you have everything done through an api it's a bit too onerous for developers. An entire system may take 2 months to code, and you're taking off maybe one month. The goal should take integration down to a couple of days (javascript libraries are quite useful for this).

Either way, best of luck! Someone is going to take this concept and run away with it and become rich. You're just as likely as the other entrants so congrats on launching!

<comment><USER6> I do think the aggregated profile is important, but I don't think a universal reputation system type of score will work. Primarily because reputation is earned within a context. The web is just too big to provide that context. This is a point that is really hammered home in the new O'Reilly book Building Web Reputation Systems. Reputations (which this basically would be) are very powerful within context, but almost meaningless outside of it. It would also have to be quite bureaucratic to control how points are awarded, which I imagine many people would find onerous.

<comment><AUTHOR> I don't know that I completely agree that the web is too big to provide context. Maybe the vastness of the web suggests that a reputation system is necessary. The fact that people want to display their wealth of knowledge, friends, followers, etc. to THEIR social graph provides enough context in my opinion.

</comment></comment></comment><comment><USER7> The first thing I did when I went to your site was to start reading the description of your product. The first thing your site did was take that description away from me.

<comment><USER8> Yeah the slider delay could use an additional 60 seconds. But as far as explaining what the product does very straight forward and I could tell what it is after reading the first slide, something that has been missing on most of the recent startup review posted here on HN.

</comment></comment><comment><USER9> How is it going to be economical for you to offer this for free? Is it ad supported? Is there a limit for the type of site that can add this? You might want to specify pageview limits or something.

Also, more screenshots showing badges, demo site, etc..

<comment><AUTHOR> Hey Daniel,

I'm leaning towards a freemium model— I don't have enough data yet to even make an accurate estimate of what makes sense.

</comment></comment><comment><USER10> (apologies for the slight brain-dumpiness of this comment)

As a game researcher, I'd like some more idea about what the supported games are, why they increase engagement, why I need Reputely rather than doing it myself. What do _you_ know about games that _I_ (as a visitor) don't? "Hey, those StackOverflow guys did it, right? It's easy, just slap images on people's accounts, right?"

The other thing that pings with me is that it is not clear to visitors that your idea doesn't put the cart before the horse. If I was fresh to the idea, I might say "But wouldn't I need a community for those numbers to matter?" I personally think it's a relationship where it helps communities build (not on it's own, mind you!), and that should be pushed somewhere.

Your copy uses the word "addicting." Be careful with this word, I know it's more common in the US, but it's fairly alien to other English speakers, for whom it looks like you have misspelt "addictive." [1]

Why do I need to give you my email address so I can see your games mechanics white paper? Why is it in PDF format? Why is this not a prominent, accessible web page?

EDIT: Also agreed with everyone saying the cycling is _way too fast_.

[1] [http://grammar.quickanddirtytips.com/addictive-versus- addict...](http://grammar.quickanddirtytips.com/addictive-versus- addicting.aspx)

<comment><AUTHOR> "Hey, those StackOverflow guys did it, right? It's easy, just slap images on people's accounts, right?"

\-- The fact that it is no where near as simple as slapping some images or badges on someone's account is what makes Reputely worthwhile.

While you, as a game researcher, are well aware of the intricacies of game design, most web developers and especially consumers, are clueless. Reputely is here to provide a standard to guide them in the right direction.

<comment><USER10> This is what I was trying to get at with my quote. The quotes were supposed to be naïve visitors, perhaps I did not make that as clear as I should. Sorry! ;)

</comment></comment></comment><comment><USER11> "Thanks for requesting Reputely's whitepaper: Best Practices: Game Mechanics.

I'll be sure to email it to you when it's ready! Thanks for your patience.

Cheers,

Dru"

That felt a little bait and switch IMO. I had the perception that I'm dropping an email address to get a white paper and now I feel tricked into get my email address

<comment><USER12> Yeah, I'm sure you're doing this to gauge the interest before writing the paper but you really need to improve the wording of the email. I clicked a link with a PDF icon saying "Download the PDF file", if there is no PDF file you should explain why and not just drop a generic "thanks for your patience".

<comment><AUTHOR> Gauging interest was the intent. I've added some clarification to the description of the form. Sorry about that!

</comment></comment></comment><comment><USER13> Wow, it seems we've had quite a few submissions lately revolving around Game Mechanics as a service. Glad to see others jump into this space.

I'm really curious to check out the API and learn how users will configure the requirements to award the points and badges. As a founder of a company who is working in this same space, I share and fully understand many of the complexities and difficulties of offering a service like this. Its oddly refreshing to see competition validate an idea and market we've been trying to develop (what seemed like alone) for so long.

I saw that on your site you wanted to Skype with people to get feedback. I'd love to talk sometime about where we see this market headed.

Best of luck! - Are you guys funded?

<comment><USER14> I missed some of the other links for Game Mechanics as a service... could you list any you remember? Thanks!

<comment><USER13> These are the few that I could find again. I found others but they were blog articles talking about Game Mechanics.

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

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

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

The companies I'm aware of that offer these kinds of services are:

<http://www.IActionable.com> \- mine :) Coming Soon

<http://www.BunchBall.com> \- rajatrocks is the founder and posted on HN years ago

<http://www.BigDoor.com> \- Just received more funding I believe

<http://www.BadgeVille.com> \- Coming Soon

<http://www.Reputely.com> \- Coming Soon

<comment><USER15> Good list Jason! I'm still here, and have been watching all the newcomers to the space with interest.

We've been providing our Nitro game mechanics platform to companies like NBC, Comcast, Hasbro, Warner Bros., etc. since 2007. We also have several startup customers and even a non-profit (Hope Lab - check out the cool work they're doing to combat tween obesity: [http://www.uncommonprojects.com/uplog/2010/06/08/introducing...](http://www.uncommonprojects.com/uplog/2010/06/08/introducing- the-gditty/)).

We've had 3 years of development, customer feedback, and on-the-job learning, so our platform's gotten pretty good, as has our team. And we have some cool stuff planned for the rest of this year and next.

Check out our website, and if you're interested in learning more, drop me a line. - <USER2>

</comment></comment></comment></comment><comment><USER12> If you haven't already, consider making the user-facing portions of the service easily localized and translated. I can see myself pitching this service to a client but the UI for end users can't be in English only.

<comment><AUTHOR> Thanks for the heads up—I hadn't accounted for that. Great point.

</comment></comment><comment><USER16> Seems like a nice idea, makes sense, just curious as a site owner, how and where I can see examples of how it would be integrated into my site.

I'd like to see more screenshots and demos please! Thanks

</comment><comment><USER17> Homepage has quite a bit that should be reworked, but I think pedalpete covered anything I would've mentioned. Some Nielson might also be helpful: <http://www.useit.com/homepageusability/guidelines.html>

Random thoughts:

-You didn't close the anchor tag on the "Reputely's Whitepaper" link in the footer

-Contact, Feedback, and Partnership in footer all link to contact, which is redundant.

-FAQ and Documentation in footer don't actually link to anything

-"Take the tour" page could benefit from having a video, or some more screenshots.

-Footer is much bigger than it needs to be

-Tabbed navigation on left of Take The Tour page really doesn't seem to have a purpose.

-Sign up page could be the same style as the contact page.

-Pricing in navigation could be called Plans & Pricing, like the button on the homepage.

-Links to homepage and blog on contact page are unnecessary, that's what main navigation is for.

Hope that helps.

</comment><comment><USER18> I'm wondering if you would be willing how offering a white paper influenced your signups? What's the conversion there?

<comment><AUTHOR> It honestly performed much, much better than I expected. I'm going to do a detailed blog post with more info about that.

</comment></comment><comment><USER19> You need a one sentence tagline, as not too many people are familiar with this market.

<comment><AUTHOR> Agreed—would love to people's suggestions on this.

</comment></comment><comment><USER20> I still have a hard time understanding what this does. I suggest providing more screenshots of each feature you have. Without an idea of what this looks like, its hard for me to sign up for this

</comment><comment><USER21> just want to stress that api , and documentation, is the only way I would even consider signing up or using this. Sorry if I wasted another comment to reiterate this.

<comment><AUTHOR> Totally understandable, especially this being HN.

API & Docs are definitely in the plans.

<comment><USER21> thanks for the comment, please do let us know when you release documentation, because currently I am building out my own solution, and if its easy enough , I would switch.

<comment><USER13> But if it was, would you pay? THAT's the important question :)

<comment><USER21> until I can see what you're offering I can't answer that question.

</comment></comment></comment></comment></comment><comment><USER22> I tried to sign up, and after submitting my information I was thrown back to the home page. Then I tried to "sign in" and that also just threw me back to home page.

</comment><comment><USER23> The first thing I clicked was 'pricing'.

I do understand that you don't know how to price it right now, but having no idea of what it _might_ cost is tough.

</comment><comment><USER24> This space is hot. Someone should fund you.</comment>


Servers for Hackers – The Book - <AUTHOR> https://book.serversforhackers.com

<comment><AUTHOR> "Your web app runs on magic. Make it run on science!" @assertchris. Perfect newsletter. Book should be excellent too. Deserves support.</comment>


Ask HN: Who here knows nothing? - <AUTHOR>

I didn't know until after my Dad passed away. Nothing killed him- he died of Lung Cancer. It was horrible to watch. <comment><USER2> Sorry to hear about your father.

"I have approximate knowledge of many things."

"This too shall pass."

</comment><comment><USER3> Nothing is the antithesis of something. The one constant there is, is nothing. Nothing isn't what you can see, but what you cannot. What is becomes nothing. Everything is nothing.</comment>


Ask HN: Do you try to code "proper" even on the first pass? - <AUTHOR>

Ask HN: On the first pass of coding something, do you hack it till you get something working or structure it well? <comment><USER2> I write code as cleanly on the first pass as I do on the last (if there ever is a last). The reason being that if I hacked it and then showed the client/my boss that it's working, it would be hard to justify the additional time to clean it up when they want it pushed to production now.

<comment><AUTHOR> Good point. But I meant working as in "your eyes only"

<comment><USER2> Gotcha...on my own projects I write very clean code, because there is never a shortage of time.

<comment><AUTHOR> Is that optimal when feedback is more IMp like early stage startup?

</comment></comment></comment></comment><comment><USER3> I blast put the most bogus half-witted garbage that could possibly half work, train of thought style. It just embarrassingly bad. I go back and clean it up almost immediately while it's still fresh in the mind.

The upside is that I usually find I need only 1/3 of what I thought I needed. It doesn't feel quite so bad to throw out huge chunks of stuff I know is so bad I wouldn't want anyone to see it anyway. The worst thing in a project is something I think is really clever but just not needed. I become irrationally attached.

</comment><comment><USER4> My code starts and stays embarrassingly bad until I _need_ to refactor it. _Eventually_ , the code improves. Very often, though, it gets thrown out entirely. Only profitable code deserves to be good.

Caveat: The above applies to my own business projets where I am the sole coder. I write better code for clients - it still starts out rough, but I refactor more frequently.

</comment><comment><USER5> 'Properly'.

But yes, otherwise I find I don't have time to fix it later. Occasionally, when I know there's a better way of doing it but am having trouble thinking of it immediately I throw a # TODO in there.

</comment><comment><USER6> I always try to code cleanly. If there is learning going on, I may not feel it is clean at the end, but it wasn't from lack of trying.

</comment><comment><USER7> You should not have a second pass it's a huge time waster. I like taking the extra time to optimize everything from the start. Maybe I won't finish my project within an hour, bu extra time helps as more ideas come to mind while coding</comment>


Ask HN: How do you get a Development job in a non-tech industry/company? - <AUTHOR>

Hi, could you share your thoughts on getting a job(contract, permanent) with software in companies or industries that are ~not~ in IT and/or doesn't even have techie culture? How have you got it before?
I'm in Brazil and not in an economic center, it's a relatively rich city(higher-end cost of living) but software companies here exist mostly to serve the government(which to the city is centered) so the work is dull. I got really entertained by the idea of getting into companies of more traditional businesses, where I could 'make a difference'(I know I'm idealizing here, but still), be closer to the business, get resourceful and on...
I imagine there's at least a handful companies around that are healthy financially but not so savvy or big that they've already have it all figured
For example: News(hopefully data visualization), hotels, logistics, commerce, real state, law... <comment><USER2> I am a developer working at a printing company. I have made myself valuable by not only what I was hired to do, but also by being able to pick up the slack of the short-handed IT department and cross-training with various other departments. Basically I found my place as a Jack of all trades and a master of a few. Hope this helps in some way.</comment>


Ask HN: How do you scale yourself? - <AUTHOR> Over the past several months, my company has started growing, and I've been getting more and more on my plate. One of the things I constantly think about now is, "How do I scale myself?" and what are the strategies to actually get there? For example: hiring an assistant, better delegation, task management through frameworks like GTD... Etc...<p>I'm curious: what tools and strategies do YOU use to get more done and scale yourself? <comment><USER2> Inform management I am stretched thin and request additional team members. There's no secret to being able to do much more in the finite amount of work hours. If management sees that you are adapting to the extra load, they will have no incentive to hire more people.</comment>


Amazon just filed a bunch of international trademarks for 'Amazon Pharmacy' - <AUTHOR> https://www.cnbc.com/2020/01/21/amazon-files-trademarks-for-amazon-pharmacy-in-uk-australia-canada.html <comment><USER2> Could be some fun counterfeits :zany:

<comment><USER3> Interesting first thought on seeing this news.

Related: [https://news.ycombinator.com/item?id=22106305](https://news.ycombinator.com/item?id=22106305)</comment></comment>


Ask HN: Applying to first job woes and rants - <AUTHOR> Hi HN,
So, I finished my  master's degree at the end of last year. I decided to rest for a while and try to enjoy christmas and new years eve (it was fun). I still was feeling burned out by January. Even though suddenly losing one of my parents a year ago destroyed me, I still managed to finish my degree on a high note (I guess?). I've helped with family matters, hanging out with my friends, preparing for interviews and working on personal projects. I've been told by a psychologist to be a little more positive and find a Job (in broad terms). I've delayed searching for a job but now I feel a lot better and I want to move on.
Ok, here are a few "real" questions: (1) Should I list technologies I had past experiences? I tried my best to focus and limit my résumé to 1 page but I feel I am leaving out a lot of stuff. (2) Should I apply to positions that list at least 3 years experience? It is hard get confidence when presented with this barrier. This Junior/Senior/Years of Experience thing seems kind of broken.
I did whatever was necessary and never relied too much on other people when I wasn't supposed to. However, I am afraid to claim expertise in anything. I'm having a hard time spinning this fact in my favor in cover letters. I would also like not to lose my AI/ML background but the entry jobs offers are few here in Portugal. I will try to continue it on the side or find a remote job (I don't know much about this).
I now started sending a few emails but no reply until now (man, at least say no to me). [I edited this text way down, I hope the main message does not get lost] I guess I will shotgun-send my résumé and see what I get. <comment><USER2> 1) List the tech you want to work with. AI/ML is hot right now.

2) Apply to anything you want even if they say 3 years experience. Error on the side of applying to things even if you don't think you are qualified. You need practice doing this.

3) Try to anything you can to expand your personal network. (Online and throughout EU if possible)

(This is what I'd do but realize my advice is heavily influenced by my experience here in Silicon Valley)

PS. Why the throwaway account? You want to make connections! Don't be afraid to ask for help on forums like this and in person. Connections are key.

<comment><AUTHOR> Thanks for the reply, I am still searching but feeling a bit more optimistic now. I will keep your advice in mind anyway I can.

It is quite hard to network living where I live right now, but I am trying to get out more to where people are. I am not sure where I can "network" online but I will try to figure that out in the coming days, maybe I should be more involved in online groups that do things that interest me.

I feel quite frustrated that I still don't have a job when some of my colleagues are making some progress, but this time allowed me to be more mindful on where I am at and what I might want. I might not do well working for other people for a long time. I want to gain first hand experience and eventually create a company with people I meet along the way. For now I just don't know how to get there.

The original post was way more personal, that is mostly the reason for the throwaway account. Thanks again.</comment></comment>


Gitconnected – The community for developers and software engineers - <AUTHOR> https://gitconnected.com/ <comment><USER2> Thanks for the share :)</comment>


The Decline In Male Fertility - <AUTHOR> http://online.wsj.com/article/SB10001424127887323394504578607641775723354.html <comment><USER2> It's worth adding that the variation in testing is extremely high.

When my wife and I had trouble getting pregnant, I was tested twice.

In the first test, my count of live critters was under the minimum threshold. In the second test, the count was at the top of the range.

All other variables were the same (time between production/delivery, time between previous production and test production and volume).

Oh, and we're expecting our first kid in 8 weeks :)

<comment><USER3> Congrats! Pretty interesting that your testing results would land at the extremes.

</comment></comment><comment><USER4> > _In general, men produce upward of 60 million sperm per milliliter of semen. > ...But below that threshold and particularly under about 20 million per ml, > their ability to help conceive drops. It may take a couple longer than a > year to conceive..._

I can't even intuitively understand how going from 60 _million_ to 20 _million_ would make any difference at _all_. There are _millions_ there, you know.

I can understand how dropping by 99% might affect things, but how on earth could a drop of 2/3 result in taking a _year_???

Does anyone know of an explanation?

<comment><USER5> Fertilization is actually an accretive process. While only a single sperm will actually fertilize the egg, a single lone sperm is not capable of accomplishing the task. The ovum has a layer of protection that prevents access. Sperm cells, in turn, have some sort of enzyme payload that breaks down this barrier. It takes a lot of this enzyme before the barrier is weakened enough for a sperm to gain access. Not enough sperm, no one's getting through.

Additionally, the female reproductive tract is generally a hostile environment. This is by design, in order to weed out sperm cells with defects. Since this is a biological system, you're going to have some variation and some females are going to have a lower sperm survival rate than others. I have no idea what the range is, but I would be entirely unsurprised to learn the variation spreads over several orders of magnitude.

<comment><USER6> Wow, so you're saying the UMP game in Starcraft 'Break the Condom' was actually fairly accurate.

</comment></comment></comment><comment><USER7> Marijuana. Seriously?

WSJ desperately trying to suggest multiple causes to sidestep blaming the obesity epidemic. Reading between the lines that sounds a lot more correlated with the trend than what I would assume is pretty consistent pot usage over the last, say, 50 years.

EDIT: remember, the idea isn't to figure out what causes reduced male fertility, it's to see which of those causes correlates best with the observation.

EDIT 2: of course by the same logic, sugar intake is what's causing the obesity epidemic (the fatty foods comment in the article is unimpressive)

EDIT 3: DanBC, excellent point about THC concentration. I didn't think of it. I can't find any data about consumption, nor am I committed enough to the subject to dig for it :)

<comment><USER8> (I'm strongly in favour of legalising drugs.)

There are a few studies showing links between cannabis use and infertility in men. Smoking cannabis is a double whammy, because tobacco use is a leading cause of erectile dysfunction.

> what I would assume is pretty consistent pot usage over the last, say, 50 > years.

That's a big assumption. I'd be interested to see any numbers to support it. Certainly in the UK it feels like people smoke more, smoke more often, and start earlier. But I don't have any numbers, this is just my opinion. I'd also be interested to see if modern cannabis actually is stronger than cannabis used in the 60s, 70s, 80s, etc.

<comment><USER9> what a crock of shit. THC levels are _not_ rising.

[http://science.howstuffworks.com/marijuana5.htm](http://science.howstuffworks.com/marijuana5.htm)

[http://www.420magazine.com/forums/cannabis-facts- information...](http://www.420magazine.com/forums/cannabis-facts- information/33637-marijuana-myths.html)

also watch [http://www.imdb.com/title/tt1039647/](http://www.imdb.com/title/tt1039647/)

> Smoking cannabis is a double whammy, because tobacco

What? You can smoke cannabis without tobacco.

<comment><USER8> > what a crock of shit.

calm down, it's a common suggestion that THC levels are rising and rather than just repeating it I asked if it is, in fact true. A simple "no" is better.

Your first link does not support your point as strongly as you seem to think. Your second link is obviously a joke - no one would present such an obviously biased source with so many cherry picked reports seriously.

</comment></comment></comment></comment><comment><USER10> Since frequency of emission leads to sperm count changes, it would be interesting to see a plot of sperm count against easy availability and societal acceptance of porn.

<comment><USER11> It would be interesting, bu migh not relevant in regard of fertility. Sperm count decreases, but sperm health increases and the consensus is that daily ejaculation sould be OK

source: [http://ivf.net/ivf/daily-sex-helps-to-reduce-sperm-dna- damag...](http://ivf.net/ivf/daily-sex-helps-to-reduce-sperm-dna-damage-and- improve-fertility-o4272.html)

</comment></comment><comment><USER12> Given that we have 7 billion people on the planet and climbing, we definitely do need to figure out what's causing the infertility so we can promote it throughout the world.

<comment><USER13> Given the distribution, western societies already know how to not reproduce. Now we need the opposite.

<comment><USER14> it's pretty simple: quit educating the females.

Think I'm joking? There are studies proving an inverse correlation between education and number of progeny.

</comment></comment></comment><comment><USER15> I've been writing up a blog post on the subject of extinction for a little why now and my theory is essentially this happening. Mankind could theoretically go extinct because we get to a point where we can no longer naturally reproduce. Sure science in reproduction has come a long way, but because it's a manual and drawn out process, I don't think science could even remedy reproduction issues faster than the population starts to decline.

Is it really a surprise sperm rates are lowering given the number of chemicals in our food, pollution and exposure to hazardous materials on a daily basis? Sperm counts aren't the only factors in reproduction but rather environment variables also play an important part in the process. What we eat, what we breath and how we live are also other serious factors and given the modern diet is anything but nutritional for a lot of people, it spells disaster in the long run.

Reading an article like this kind of scares me. Because it kind of gives what I've been debating internally inside of my head for the last few weeks. The day we stop being able to naturally reproduce is the day mankind is in some serious trouble.

<comment><USER16> > Is it really a surprise sperm rates are lowering given the number of > chemicals in our food, pollution and exposure to hazardous materials on a > daily basis?

Why would it affect sperm count but not longevity?

<comment><USER15> We might be living longer, but that doesn't mean we're any healthier. I think longevity has something to do with medicine reaching a point where we can keep terminally sick people alive for years before they die.

</comment></comment></comment><comment><USER17> One thing I've heard that fertility surgeons joke about is that by providing ICSI ([http://en.wikipedia.org/wiki/Intracytoplasmic_sperm_injectio...](http://en.wikipedia.org/wiki/Intracytoplasmic_sperm_injection)) they are "breeding more work for their sons."

Basically, people/genes that would have died out are being helped to continue in the gene pool.

</comment><comment><USER18> I wonder if it could just be that porn is more accessible... AKA release one payload, take some time to recover fully?

</comment><comment><USER19> This is an old discussion around the topic: [https://news.ycombinator.com/item?id=4891885](https://news.ycombinator.com/item?id=4891885)

</comment><comment><USER20> I love how everyone is so worried about male fertility and how it is referred to as a sperm count 'crisis'. The real elephant in the room which is never spoken about is overpopulation of our planet. This is far bigger problem and in my opinion, any slight percentage drop in male fertility would be a blessing in disguise!

</comment><comment><USER21> My guess: Skinny Jeans.

</comment><comment><USER22> Get everyone out in the cold air wearing kilts. The testicles hang on the outside for a reason.

BTW have my third kid due in a couple of months. So survival of the fittest is working out fine for me.

</comment><comment><USER23> I'd like to see more studies on the effects of having a cell phone in your pocket all day long because:

[http://www.dr.dk/Nyheder/Indland/2013/05/16/131324.htm](http://www.dr.dk/Nyheder/Indland/2013/05/16/131324.htm)

Plant sprouts won't germinate when placed near a wireless router. Also sleeping with a cell phone next to your head apparently affects concentration the next day.

<comment><USER24> > Plant sprouts won't germinate when placed near a wireless router. Also > sleeping with a cell phone next to your head apparently affects > concentration the next day.

If I germinated a plant sprout in my room near a wireless router, would you stop going around making this claim?

<comment><USER25> I'd happily have nothing germinate near my router if it would just route properly. It updates new firmware every time I reset it. Turns out this can cause problems. Who'd have thought? Thanks Orcon, New Zealand.

</comment></comment></comment><comment><USER26> Is marijuana the answer to overpopulation???

<comment><USER27> No, giving women education and right to abort does.

</comment></comment><comment><USER28> And this is bad why ? :) We don't need more people on this globe, less would be better !

</comment><comment><USER29> I'd like to see if the pattern of decline correlates with Banana Consumption.

This isn't a joke.

</comment><comment><USER30> Mobile phones?

<comment><USER31> Unlikely if you look at the chart that goes with the article [http://si.wsj.net/public/resources/images/OB- YE989_MFERTI_G_...](http://si.wsj.net/public/resources/images/OB- YE989_MFERTI_G_20130716114103.jpg) cell phones weren't common in France in the early 90s yet that's when the biggest drop occurred.

<comment><USER29> Dow Chemichals got rid of its stock of some very effective pesticides in the late 80's, on the term that they would never be sued.

</comment></comment></comment><comment><USER32> We have much bigger problems than not as many humans being born (assuming the study is correct).</comment>


Ask HN: What's the point of this kind of API? - <AUTHOR> I have seen some api requests on the web with a https GET response body starting with the following characters:<p>)]}'<p>Then this characters are followed by arrays of elements without keys(as a JSON). What's the point of having this structure of response requests? <comment><USER2> It prevents the response from being evaluated as Javascript.

In some older web browsers (like Firefox 2.0), this was required to prevent an attack where the Array constructor is overridden to capture arrays within a response. This no longer works on any modern browser, but a lot of web services still attempt to defend against it.

[https://haacked.com/archive/2008/11/20/anatomy-of-a- subtle-j...](https://haacked.com/archive/2008/11/20/anatomy-of-a-subtle-json- vulnerability.aspx/)

</comment><comment><USER3> [https://stackoverflow.com/questions/26955167/json-data- that-...](https://stackoverflow.com/questions/26955167/json-data-that-starts- with-closing-brackets)

</comment><comment><USER4> It disables the JS from running in an IFrame I believe.

Companies like Google and Facebook use this to prevent others from embedding their pages in others.

</comment><comment><USER5> You will need it only depending on the type of API you are building. If redirects etc are not an issue then your won't need it. APIs are an attack vector for hackers.

</comment><comment><USER6> To prevent xss and other type of attacks lose cookie stealing or redirects.</comment>


An even smaller world's smallest LED blinky - <AUTHOR> https://hackaday.com/2019/04/11/an-even-smaller-worlds-smallest-led-blinky/ <comment><USER2> The video mentions an 0805 resistor for scale.

That is 2 mm by 1.2 mm.</comment>