Secure Rust Guidelines - <AUTHOR> https://anssi-fr.github.io/rust-guide/ <comment><USER2> I personally strongly disagree with:

Functions or instructions that can cause the code to panic at runtime must not be used.

First of all, they kind of dodge this later by saying "Array indexing must be properly tested" (else it can panic) -- everyone thinks they write code which is "properly tested".

Personally, I often write panicing code -- if the code gets in a state where I have no idea how to fix it, I panic. For some code it is important it does quit, but I'd much prefer more code paniced than tried to carry on and ended up creating other problems.

Also, in rust if we don't want to panic we need to never use array indexing and never use integer division, just to start.

Of course, it's fine to write code which plans to never panic, but I think it would be better to say "Have a formal 'panic plan'", where either one panics early, or tries to never panic.

<comment><USER3> > First of all, they kind of dodge this later by saying "Array indexing must > be properly tested" (else it can panic) -- everyone thinks they write code > which is "properly tested".

You're skipping half the recommendation though:

> Array indexing must be properly tested, _or the get method should be used to > return an Option_.

emphasis mine

> Also, in rust if we don't want to panic we need to never use array indexing > and never use integer division, just to start.

I mean, that's literally the block above the one you quote:

> Common patterns that can cause panics are:

> * using unwrap or expect,

> * using assert,

> * an unchecked access to an array,

> * integer overflow (in debug mode),

> * division by zero,

> * large allocations,

> * string formatting using format!.

>> Rule LANG-NOPANIC

>> Functions or instructions that can cause the code to panic at runtime must not be used.

The bit you quote is really a additional reminder that array indexing is not panic-safe.

<comment><USER4> _You 're skipping half the recommendation though:_

 _> Array indexing must be properly tested, or the get method should be used to return an Option._

Fwiw, for anyone who's dabbled with Haskell this is SOP. Any result that could be undefined is returned as a Maybe (Haskell's version of Option). If this seems odd to anyone, understanding it in Haskell will probably help understand it better in Rust too:

[http://learnyouahaskell.com/a-fistful-of-monads#getting- our-...](http://learnyouahaskell.com/a-fistful-of-monads#getting-our-feet-wet- with-maybe)

[https://en.wikibooks.org/wiki/Haskell/Understanding_monads/M...](https://en.wikibooks.org/wiki/Haskell/Understanding_monads/Maybe)

<comment><USER5> Er, don't Haskell's head and (!!) functions default to throwing an exception?

        $ ghci
        Prelude> let a = [3, 4, 5]
        Prelude> a !! 0
        3
        Prelude> a !! 3
        *** Exception: Prelude.(!!): index too large

        Prelude> head []
        *** Exception: Prelude.head: empty list

I don't think Haskell is really different from Rust in this respect. Both have a wrapper type for optional values with good syntax, but in both, there's still _some_ syntax so common operations sometimes choose to skip it.

In fact, Hoogle doesn't seem to find me a function like Rust's .get() in the standard library, just a handful of third-party packages: [https://hoogle.haskell.org/?hoogle=%5Ba%5D+-%3E+Int+-%3E+May...](https://hoogle.haskell.org/?hoogle=%5Ba%5D+-%3E+Int+-%3E+Maybe+a&scope=set%3Astackage)

<comment><USER6> > Hoogle doesn't seem to find me a function like Rust's .get() in the standard > library

In practice, you don't really need one - the safe alternative to "xs !! n" is pattern-matching on the result of "drop n xs", as that's [] if xs has ≤n elements:

[https://www.haskell.org/onlinereport/standard- prelude.html#$...](https://www.haskell.org/onlinereport/standard- prelude.html#$vdrop)

<comment><USER5> Sure, that seems syntactically more cumbersome than 'if let Some(foo) = xs.get(n)' or 'xs.get(n).map(|foo| ...)' in Rust, but yes, you can do it. As I said, because _both_ the Rust and Haskell versions are more cumbersome than using the version that raises an exception/panics, _both_ Rust and Haskell's standard libraries choose to give you a syntactically-easier alternative that isn't a total function.

All I'm saying is that Haskell doesn't seem to do anything different here - Rust has incorporated the lessons from Haskell's type system. (As someone who fell in love with Haskell a long time ago but never got to use it professionally, this is basically why I like Rust.) Is there something Haskell does _that Rust does not do_? I'm not trying to say Haskell is insufficient - I'm just refuting the claim that Rust is insufficient and should act more like Haskell.

<comment><USER6> Sure, I don't disagree - I meant only to add context for anyone reading who was unfamiliar with Haskell, lest they come away with the impression that the lack of a .get()-equivalent was some kind of egregious oversight.

</comment></comment></comment></comment></comment></comment></comment><comment><USER7> I'm having problems fulfilling this requirement in my libs: "Crates providing libraries should never use functions or instructions that can fail and cause the code to panic."

The Rust standard library Vec, HashMap etc. can cause a panic in Rust, if the device (such as a mobile phone with a small memory) runs out of memory.

C and C++ standard libraries (malloc, std::vector, std::map..) can handle those situations by returning null or throwing an exception.

I wish Rust had some easy way to recover from out-of-memory situations when using the standard library. I have been considering writing my own out-of- memory safe Vec, HashMap etc, but it can't be the right way to do it..

<comment><USER3> Yes that is one of the primary failures of Rust at the moment: to my knowledge it currently has no good way to safely manage allocation failures (it also has serious issues with stack overflows).

This is an issue with all heap-allocating construct, not just collections but also Box or Rc.

> I wish Rust had some easy way to recover from out-of-memory situations when > using the standard library. I have been considering writing my own out-of- > memory safe Vec, HashMap etc, but it can't be the right way to do it..

Maybe look at the embedded space there? There might be no_std third-party libraries which handle these issues. Possibly on top of alloc as the (unstable[0] and obviously unsafe) `Alloc` trait does have a concept of allocation failure.

[0] [https://github.com/rust-lang/rust/issues/32838](https://github.com/rust- lang/rust/issues/32838)

<comment><USER8> > Yes that is one of the primary failures of Rust at the moment: to my > knowledge it currently has no good way to safely manage allocation failures

So, sort of yes and sort of no.

The data structures that allocate in the standard library do not let you handle allocation failure. However, if you write your own, the global allocator lets you determine if failure happened, and then you can do whatever you want with it.

<comment><USER9> I think Rust got it right, here.

Dealing with allocation failure _gracefully_ is hard and requires a lot of extra code.

For most applications the best default is to panic and handle it up the stack rather than pay the programming overhead of handling allocation failure explicitly in every last nook and cranny. The Rust standard library rightly optimizes for this use case.

For the embedded or critical-safety application spaces, where you really do want to handle allocation failure gracefully, you need something other than the standard library. Letting that "something" develop slowly out in the community is a good call.

</comment></comment></comment></comment><comment><USER10> This is published by the ANSSI[1], National Cybersecurity Agency of France. They do quite a good job at publishing security guide.

[1] [https://www.ssi.gouv.fr/en/](https://www.ssi.gouv.fr/en/)

</comment><comment><USER11> I found at least one problematic section when scanning:

> The environment variables RUSTC, RUSTC_WRAPPER and RUSTFLAGS must not be > overriden when using Cargo to build project.

This is simply not true at all. Mainly build cache systems like sccache work by wrapping rustc, there is no reason why using a build cache should be forbidden.

(Through currently rust support of sccache is still not perfect and there are some limitations, doesn't change that the rules are to broad.)

I also wouldn't be surprised if there are some rustc flags not exposed in cargo profiles which allow trigger some security mechanisms in llvm which are not enabled by default but beneficial for your project.

Like always the important think is that you understand what you do and want implications it had.

</comment><comment><USER12> The context that I was missing at first:

> The Agence nationale de la sécurité des systèmes d'information (ANSSI; > English: National Cybersecurity Agency of France) is a French service > created on 7 July 2009 with responsibility for computer security [1].

I didn't know about "cargo-outdated". I liked having "npm outdated" within the JavaScript ecosystem, so I'll give this a try.

1\. [https://en.wikipedia.org/wiki/Agence_nationale_de_la_s%C3%A9...](https://en.wikipedia.org/wiki/Agence_nationale_de_la_s%C3%A9curit%C3%A9_des_syst%C3%A8mes_d%27information)

<comment><USER13> `cargo-outdated` is mint. If you haven't already, consider installing `cargo- edit` too! It adds `cargo add`/`cargo rm` to add/remove crates, as well as `cargo upgrade` to bump semver versions.

[https://github.com/killercup/cargo-edit](https://github.com/killercup/cargo- edit)

<comment><USER3> There's also cargo-crev which is pretty neat.</comment></comment></comment>


Proposal: "Statements as Expressions" using do - <AUTHOR> https://ponyfoo.com/articles/proposal-statements-as-expressions-using-do <comment><USER2> Help me out if I'm missing something important, but this doesn't really seem to add much except for the conceptual overhead of another control structure.

The examples given in the article are as clear or clearer without the do syntax. Compare:

        [1, -1, -0.5].map(x => do { if (x > 0) { x * 10 } else { -x * 10 } })

to

        [1, -1, -0.5].map(x => { if (x > 0) { return x * 10 } else { return -x * 10 } })

as well as

        var data = do {
          const data = pullSomeData()
          doSomethingElse() // sideEffect
          data
        }

versus

        const data = pullSomeData()  // or `var` if you wish
        doSomethingElse() // sideEffect

Perhaps a more significant example is warranted here. My suspicion is that if you get code complicated enough to justify a `do` block, it's complicated enough to justify a function that can be independently tested.

<comment><USER3> I agree that the examples aren't particularly motivating. But I think it really shines in JSX blocks (or other simple branches in literal data structure definitions). It's also super helpful when needing to initialize several variables based on branching on several other values. Having expression-if combined with array unpacking assignment makes this a breeze.

</comment></comment><comment><USER3> Oh yes! Besides pattern matching, this is the biggest improvement to Javascript control flow I've been waiting for. It's a shame it can't be expression oriented by default, but I suppose that in the handful of cases expression-orientedness really shines, typing "do" is a small price to pay.

I have been wondering, it's there any downside to expression-orientedness? Time and again, it seems to pay its weight. JS, for example, has arguably been saved by function expressions.

Random niche question, would "do...while" now be an expression?

</comment><comment><USER4> There was also talk of an asynchronous do notation proposal, and to add monadic like functionality: [https://esdiscuss.org/topic/monadic-extension-to- do-notation](https://esdiscuss.org/topic/monadic-extension-to-do-notation)

The problem is that these proposals haven't really advanced very much in the spec process.

<comment><USER3> I'm a fan of `async do` with `await`, rather than a poorly thought out imitation of Haskell's `do`.

</comment></comment><comment><USER5> I'm not sure I got the explanation right. Is this syntax sugar for `(function(){ ... })()` ?

<comment><USER3> More or less, with `return`s sprinkled in that desugaring.

Or you might say the syntax you quoted is a workaround for lack of expression- orientedness.</comment></comment>


Show HN: Astro-Bot – A programming question with every new tab - <AUTHOR> https://chrome.google.com/webstore/detail/astro-bot/acjiedbilhbchmjblapmekfajpplpgdo <comment><USER4> Pretty cool! However, some riddles are incorrect, for example this one has two errors:

      def foo( vals ):
        output = vals[0]
        for x in vals[1:]:
          if output < x:
            output = x
        return x

1\. It should return output

2\. The answer should be "The maximum value", not "The minimum value"

Also, it could be nice if after you solve a riddle you would get a new one.

<comment><AUTHOR> Thanks for pointing this out! It's fixed now

</comment></comment><comment><USER5> Wouldn't a better idea be to show a question on Stack Overflow which is somewhat upvoted but still without an accepted answer?

<comment><USER6> Sounds good, doesn't work.

<comment><USER7> Doesn't work as in technically? or the concept? or legally?

</comment></comment></comment><comment><USER8>
        $ git checkout -b feature

The answer to this is wrong -- got green on "merge two branches" rather than "create and then checkout a new branch called 'feature'".

<comment><AUTHOR> Ha whoops, thank you for noticing this -- I've updated the answer.

</comment></comment><comment><USER9> Why would I want to be distracted while doing a task that serves a certain purpose? I must be the only one not just opening new tabs out of boredom :P

<comment><AUTHOR> That's actually why I made it so nothing happens after you answer a question. Ideally you open a tab and every now and then you take a minute or so to think one over and answer.

</comment></comment><comment><USER10> The following is incorrect for finding a missing number in a sequence.

      func foo( _ nums: [Int] ) -> Int {
        var sum = 0
        var _ = nums.map {sum += $0}

        return (nums.count * ((nums.count+1) / 2)) - <USER3>
      }

The last line should be

      return ((nums.count+1) * ((nums.count+2) / 2)) - <USER3>

The count of nums will give the incorrect answer since it's already missing a value.

<comment><AUTHOR> You're absolutely right, thanks for noticing this. There was also a bug with the parentheses I hadn't caught.

</comment></comment><comment><USER11> I enjoyed it, but you should allow me to disable random HackerNews links. That's not the purpose of the extension.

<comment><AUTHOR> Great suggestion - I'll add an option to disable that.

</comment></comment><comment><USER12> Nice! It would be cool if there was some kind of points to denote how many questions we have answered correctly.

<comment><AUTHOR> Scores will be coming in the next few days. I'm also planning on adding an (opt-in) leaderboard so you can see how you compare to other people.

Is a leaderboard something that would appeal to you?

</comment></comment><comment><USER13> Is there a Firefox version?

<comment><AUTHOR> It will be coming this week or next - I'll reply here when I've released it.

</comment></comment><comment><USER14> #include<stdio.h>

int main() { int array[] = { 1, 2, 3, 4, 5}; int *ptr; ptr = a; ptr++;

        return 0;

}

This won't compile, but the answer says it should be 2

<comment><AUTHOR> Thank you, it's fixed now.</comment></comment>


Atari Asteroids: Creating a Vector Arcade Classic - <AUTHOR> https://arcadeblogger.com/2018/10/24/atari-asteroids-creating-a-vector-arcade-classic/ <comment><USER2> I wish I had a quarter of all the quarters I dropped down the slot in an Asteroids arcade cabinet. I just know I would go right out and find another machine and start blasting rocks.

The 7-Eleven where I grew up was just a convenient place to get a Slurpee or a Big Gulp before they got their first Asteroids machine. Word got out in the small town where I grew up and we would all take any opportunity to go down and try to beat the latest high score. Having your initials on the leader board would create jealousy among my male peers and desire among the females. Who wouldn't want to be seen with the high-score holder? We spent hours trying to outdo each other. Competition was fierce and taunting was normal behavior.

The store had several other machines over the years including Frogger, Space Invaders, Supreme Commander (is that a real one - the nuclear bomber game), Centipede, etc. and periodically the owner would rotate new machines in and old ones out. The one game that he had two of was Asteroids. It was extremely popular. Other places in town also got in on the arcade games bandwagon and before long you could play at the pool hall (spent a lot of time there too), almost every beer joint, and even some fast food joints. Anywhere you might see a crowd of people waiting for something became a great place to give them a way to spend their time and their quarters before you soaked them on the main event.

While working with one crew in town we passed our time gambling by pitching quarters. The quarter closest to the line would win all. We even used the lane stripes on the highway in some spots if the traffic was low or non-existent. There was no better feeling than getting off work with a shit-ton of someone else's quarters to drop in the slot.

I love that game. I bought an emulator version for my kids when they were old enough to understand video game controls and they love it too.

I worked with a guy in Houston several years ago and we were shooting the breeze when he mentioned that he had just bought several pinball machines to restore. I asked him what his favorite arcade game had been while he was growing up. He told me he only played pinball. I was hoping he could be my new best friend and we could hang out and waste time with his Asteroids game but nope, just another Pinball wizard loser. ;)

<comment><USER3> How common was the later revision (small saucer fires immediately when it appears, and can aim at you across the wrap around) compared to the original?

MAME makes the newest revision the 'default' (in terms of their ROM naming) so I sometimes feel like that's the one I 'ought' to play but it's very much harder than the original, which I enjoy more (while currently I'm not good enough to deliberately 'hunt' the saucers anyway).

<comment><USER4> In my area, there was one. A good player could tell straight away.

</comment></comment></comment><comment><USER5> If you love Atari vector games and haven't read Jed Margolin's primer on how they did it, this is a great technical read:

The Secret Life of Vector Generators: [http://www.jmargolin.com/vgens/vgens.htm](http://www.jmargolin.com/vgens/vgens.htm)

And it's companion piece, the Secret Life of XY Monitors: [http://www.jmargolin.com/xy/xymon.htm](http://www.jmargolin.com/xy/xymon.htm)

</comment><comment><USER6> If you look at the letter from Thomas M. Saunders, Esq. towards the middle of the page, you'll notice a handwritten reference to Skip Paul. This is the same Skip Paul who championed our game, 13 years later, while a senior executive at Universal Studios -- and who in fact decided the character of Crash should be a bandicoot rather than a wombat. (The article also quotes Mark Cerny, who was our producer, and who was brought in to Universal by Skip.)

</comment><comment><USER7> If you haven't seen an Asteroids cabinet in action, I suggest you find one at an arcade museum near you. Actual Asteroids is quite different from any port or emulation of it. The slow-decay phosphor leaves visible trails for your ship and shots, and the machine has control over electron-beam intensity in a way that raster units do not, which means that your shots and enemy saucers glitter in the dark, creating a "spacey" atmosphere that's hard to replicate on a raster display.

<comment><USER8> And Tempest too - just isn't the same without the dial/paddle!

<comment><USER9> I would say that Tempest is even more of a true classic. It's immediately accessible even to today's audience.

</comment></comment></comment><comment><USER10> I love that the proposal fit on a one-page mimeographed form.

I also find it kind of funny that these are museum pieces now. I played a lot of Asteroids as a 12-year-old - the neighborhood indoor archery range bought or leased one, and nearly every day after school there was a small gaggle of kids playing it. This and "Battlezone" were part of my arcade gaming coming- of-age in the early 80s.

<comment><USER9> I was a volunteer at a video game museum. I was also a kid playing Space War, Asteroids, and Battlezone. There's a big difference between kids nowadays and kids back then, in terms of how much problem solving and science they're willing to do to figure out a game!

Basically, most kids nowadays will just walk up to Battlezone, wiggle the sticks for 2 seconds, which just pivots/vibrates the tank for 2 seconds, then they give up. (A few adults were like this too.) Of the kids who didn't give up, there was one who didn't figure out the 3D world also existed out of the field of view. He asked of the radar screen, "What's that clock thing in the top?" ("It's a radar screen." \-- blank look. "It's a minimap." \-- Comprehension!)

I have a MMO Asteroids style game up online. At one point, I hired a high school aged kid to do testing. His first reaction: It doesn't go where I point it! It's impossible to strafe! For the younger kids reading this comment 1) is the point of the mechanic and 2) It's not, if you grok basic physics.

I've noted that the "Asteroids" movement mechanic is generally hugely bastardized and dumbed down for modern audiences in today's games, to the point that it breaks the expectations of anyone who has skill with the mechanic in Asteroids. "Heat Signature," and "SPAZ" are two examples of this.

<comment><USER10> _Basically, most kids nowadays will just walk up to Battlezone, wiggle the sticks for 2 seconds, which just pivots /vibrates the tank for 2 seconds, then they give up. (A few adults were like this too.) Of the kids who didn't give up, there was one who didn't figure out the 3D world also existed out of the field of view._

Wow. And I thought the youngest generation was pretty quick when it came to figuring out interfaces and liked old-school games.

Maybe the interest is limited to pseudo old-school interfaces based on blocky graphics, like Minecraft or Nintendo-ish platformers?

<comment><USER9> _Wow. And I thought the youngest generation was pretty quick when it came to figuring out interfaces and liked old-school games._

I think that mostly has to do with subculture and what one's peers are interested in. I never had that much interest in platforming mechanics. (Honestly, I'm about as bad as that game journalist who got called out for his clumsiness with the Cuphead tutorial.) To a lot of hardcore "gamers" that marks me as a non-gamer. However, my clumsiness with platform mechanics isn't any different than most other's illiteracy with the Asteroid movement mechanic. It's just that certain mechanics are subscribed to and practiced more than others.

Also, most successful games nowadays come with fairly extensive tutorials, and even if they don't but are still popular, then there are tons of YouTube videos which can be used as reference. In the 80's, you just had instructions printed on the arcade console and a few screens animating basic game mechanics. We figured things out because we had to, or we got advice from friends who figured things out. In 2018, there are so many games, no one really knows what to do with them all, so you skip over everything that doesn't grab you immediately or you go and do what all your friends are doing.

So yeah, they probably would be as quick, but in 2018, only a very few are going to bother.

</comment></comment></comment></comment><comment><USER11> If you have never seen one, I strongly recommend seeking out a real vector arcade machine. The monitor has a beautiful, otherworldly appearance that can't be captured in photos or emulation. Somehow the lack of the raster grid makes the image feel more tangible. In an arcade the vector machines have an aura that even the best raster machines don't have.

<comment> cbm-vic-20 For me, it's the intensity and brightness that really stand out. In Asteroids, the ship and rocks are clear, smoothly drawn straight lines, but the shots from enemy ships are intensely bright points that actually make a small circle around it on the CRT also glow faintly.

<comment><USER12> The first time someone sees what Asteroids really looks like is pretty special. Those ridiculously bright bullets burn themselves into your retina in a way that simply can't be emulated.

</comment></comment></comment><comment><USER13> Stuff like this always reminds me of this amazing vector-based home gaming machine from the 80's: [https://en.wikipedia.org/wiki/Vectrex](https://en.wikipedia.org/wiki/Vectrex)

<comment><USER14> That was a good machine! One of my cousins received a copy for a Christmas/Birthday present and we spent hours playing it.

The gel-overlays were an inspired solution to making the displays more interesting.

</comment></comment><comment><USER15> Vector game monitors created a look that's either impossible or really hard emulate well with pixel-based monitors and scan-line-based CRT's. A beam of electrons can dwell on a single spot or narrow area for a relatively long period of time, making it _glow mega-bright_.

It's roughly the same technology as a CRT, except instead of periodic scan lines, the "beam aimer" can dynamically point to wherever it wants on the screen. It's kind of like some laser shows.

I'd love to see one again and show it to my (grown) kids.

<comment><USER16> You could get a laser projector and port asteroids to it (like this guy did)

[https://m.youtube.com/watch?v=FkHjG759ABY](https://m.youtube.com/watch?v=FkHjG759ABY)

<comment><USER17> A buddy of mine built his own RGB laser projector for about $400 back in 2013 or so, and got MAME to work with it. But the games typically try to draw too many lines for a laser projector to keep up with, so you either need multiple, and split up the lines among the projectors and carefully align the projectors. Anyway we learned that filming laser projections is hard, and doesn't look like it does in real life. [https://www.youtube.com/watch?v=S2JKr- Vkz8A](https://www.youtube.com/watch?v=S2JKr-Vkz8A)

[https://www.youtube.com/watch?v=eA6pvAZ3nq4](https://www.youtube.com/watch?v=eA6pvAZ3nq4)

<comment><USER16> Very cool. A lot of games i forgot we're cector based.

Battle zone, tempest, Star Trek and some game with vector blimps and space squids (world war vi?). How did the mame output which is usually to a crt translate to your projector?

<comment><USER17> Word War vi[1] is a little game I made long before the laser projector, and we were looking for things to do with the projector, so I converted word war vi to be able to use it.

You can look in the commits here to see how MAME is hooked to the projector. [https://github.com/jv4779/openlase- mame/commits/master](https://github.com/jv4779/openlase-mame/commits/master)

I believe the jist of it is MAME already has to start with lines meant for a vector display and rasterize them one way or another for a modern computer. Before this happens, the data can sent to the openlase library[2] which generates signals on 5 channels of audio: 2 channels for control of X and Y galvos, and 3 channels for red, green, and blue laser power control. These signals then get sent to amplifiers and then to galvos and laser controls.

[1] [http://smcameron.github.io/wordwarvi/](http://smcameron.github.io/wordwarvi/) [2] [https://github.com/marcan/openlase](https://github.com/marcan/openlase)

</comment></comment></comment></comment></comment><comment><USER18> If you like this, you might appreciate [https://www.reddit.com/r/TheMakingOfGames/](https://www.reddit.com/r/TheMakingOfGames/)

</comment><comment><USER19> We had one at Quarter Horse here in Durham until very recently. Really wanted to keep it in the lineup but it didn't get enough plays :(

</comment><comment><USER20> When I was a kid, my parents would drop my off at a daycare called Kids Time Out.

This was the early 80s and they had a cocktail version of Asteroids. I mastered it! I could play it all day!

One of my favorites to this day, along with Gauntlet, STUN Runner and VR Racing/Daytona USA.

</comment><comment><USER21> I had always assumed that Asteroids was a spin-off of Space War, seeing as the latter also used vector graphics and one of the player ships was the same design as the Asteroids ship. I loved Space War, but it was incredibly rare (in the UK)

<comment><USER9> Space War was the very 1st arcade videogame I played, ever!

</comment></comment><comment><USER22> So are you gonna play ships or rocks?

<comment><USER4> Alternate</comment></comment>


Using Clojure for Web Apps - <AUTHOR> https://github.com/tbsschroeder/using-clojure-for-web-apps <comment><USER2> Here's the video: [https://www.youtube.com/watch?v=dzGuaO38XDw](https://www.youtube.com/watch?v=dzGuaO38XDw)

<comment><USER3> thanks!

</comment></comment><comment><USER4> Some of my favorite Clojure libraries in this space:

\- instaparse: takes EBNF (and other formats) as a string and gives you a parser instantly (!!!) [https://github.com/Engelberg/instaparse](https://github.com/Engelberg/instaparse)

\- re-frame: React-Redux alternative that IMO is much easier to work with [https://github.com/day8/re-frame](https://github.com/day8/re-frame)

\- reagent: React wrapper [https://reagent- project.github.io/](https://reagent-project.github.io/)

\- ring [https://github.com/ring-clojure/ring](https://github.com/ring- clojure/ring)

\- fulcro [https://github.com/fulcrologic/fulcro](https://github.com/fulcrologic/fulcro)

More than any library, though, what keeps bringing me back to Clojure is its incredibly blissful set of persistent data structures. It's a pernicious accident of history that we are taught to accept references to mutable objects as normal, inevitable, and desirable in most CS curricula. It is much easier to develop, debug, and maintain immutable data structures instead, and I consider my good fortune every time I get to debug something in Clojure rather than in some reference-laden OOP soup.

<comment><USER5> > desirable in most CS curricula.

most of the alogrithms and datastructures that you learn in CS were developed using mutability.

I am not sure that we can even develop immutable equivalents for most of them with similar time/space complexities.

<comment><USER4> Sure, and we could argue about whether mutable code is necessary at systems layers. But at application layers (i.e., the ones most developers work at), cost of development is almost always going to come before performance, and I think it's clear by now that OOP, at least insofar as it has been instantiated by Java, C#, and friends, has not delivered on its promise to simplify application development.

</comment></comment></comment><comment><USER6> I've been slowly learning Lisp to hack on Emacs, org-mode and org-babel. Main goal being to turn AWS JSON data into org-mode headings and org-babel data to do further work on.

Very much a side project and I'm a bear of very little brain, so it's taking me a long long time.

Seeing Clojure and other Lisp stuff in the wild gives me hope that I can lean on enough people's documentation and source that I can eventually learn what I need.

I know some folks sneer a little at Lisp, but I really enjoy trying to learn it. I haven't felt as motivated to learn a coding language since about ten years ago when I used Perl to transfer/munge data from different LDAP systems into Zimbra.

So, thank you for sharing, this is fascinating stuff.

<comment><USER7> > I know some folks sneer a little at Lisp

I wonder why.

Some developers I know and hold in high regard have almost venerated Lisp, so I've always thought there must be _something_ to it. I just thought it wasn't something you could actually use IRL, but I was wrong. I found this out when I was recently motivated to learn Clojure, and now I am starting to grok their admiration.

<comment><USER8> It will depend on whom you talk to - perhaps how old they are, and certainly where they come from (experience wise, education wise, etc.)

The usual easy excuse is about parens, but that complaint has been put to rest so many times that it's not worth replying to anymore. (And people said the same thing about Python whitespace, but now Python is at or near the top of the pile.)

<comment><USER9> Python has too few parentheses, Clojure has to many. There's just no winning.

Ultimately, these complaints are superficial and serve only to justify one's laziness.

<comment><USER8> Clojure has the same number of parens as Javascript, C/C++, Java, and similar languages have parens+squiggle-brackets.

(print "foo") vs print("foo"). same same.

There's so much more to it than this. I can say without reservation that people who do not take a couple/few weeks to learn a Lisp just do not know what they are missing, and their arguments against it are viewed as children who lack enough experience to know what they are rejecting.

<comment><USER10> >(print "foo") vs print("foo"). same same.

If you look at things other than function calls, it starts to look different:

        let x = 5,
            y = 10
        foo(x,y)

vs

        (let [x 5
              y 10]
          (foo x y))

I actually like Lisps and think the S expression syntax is one of their best features, but I'm not going to pretend there are the same number of brackets in Lisps as there are in C family languages.

<comment><USER8> I can't reply to your lower example because it's too deep, but I would point out that clojure does not have the other symbols - equal and comma.

In your lower example, Clojure has only one more non alphanumeric character than the other example.

Furthermore, in Lisp, you always know that you have (function-name param param etc). Reading it becomes not just easier - it removes an entire layer of abstraction (syntax rules). Also, with smart editors, you gain the ability to move these around rapidly in ways that you simply cannot do with other languages.

Funny thing is, the biggest annoyance I have when not using Clojure is having to type commas between items in data structure. [1 2 3 4 5] just looks so much cleaner than [1, 2, 3, 4, 5]. I forget who wrote it, but they complained of seeing all the mouse turds "," in normal programming languages.

<comment><USER11> Even math notation dispenses with the silly commas in matrix notation, which so nice it gets used for vectors also.

</comment></comment></comment></comment></comment></comment></comment></comment><comment><USER12> If anyone is interested, there is an up and coming Clojure web framework called Coast, [https://coastonclojure.com/](https://coastonclojure.com/)

For those that aren't as familiar with Clojure - there isn't a rails or Django for web apps, so Coast is trying to fill that void.

<comment><USER13> I've used Luminus to fill that space, and I gotta say I don't think that's the best way to go for Clojure.

Getting started with Luminus was fine, but it was often very confusing and I didn't understand a lot, whereas when I added things as I needed them and checked out a couple libraries, I had a lot easier time debugging what was wrong.

What's going to make Coast different?

<comment><USER14> IMO languages like Clojure (or Go) don't need a fully powered batteries included web framework like Rails or Django. The approach to pick together what you actually need (router, db bits and pieces, etc) with composable libraries works really great

<comment><USER15> After having gone through this, I now disagree.

There are a vast many things in which I am not an expert. The pick and choose / compose your libraries / lego approach sounds great until your trying to weigh different options (of which none seem to have a wide enough install base to be truly battle tested).

Is buddy/buddy-auth the way to go for security? Or is it Friend? The former seems to receive more recommendations as of late, whereas the latter has more activity on github. These are not the problems I want to be solving when building something.

I love the language, but the quality of Clojure's web ecosystem is... questionable.

If I were to build another webapp in Clojure, I think I'd just use something widely installed like Jersey for actually interfacing with the outside world. It'll be crufty Java, but it has nice things like StackOverflow activity, massive docs, giant userbase, etc.. etc..

<comment><USER8> You express exactly what has kept me from doing webdev with Clojure, despite my (now perhaps irrational) love for the language.

I will learn whichever language allows me to get my site/app done as quickly as possible at first. Later after I have refined and refactored enough to know what's up... then I may decide to change.

Nextjs (despite the javascript), Rails (Ruby is great!... not Clojure, but pretty good), Django (Python is low-pain, low-effort), etc. are all easy quick ways to actually get something done BEFORE you really know what you're doing. This is critically important for those of us who don't spend all our time doing public-facing web apps.

<comment><USER16> As someone who tries to use Clojure everywhere I can, its very hard to beat Rails for pushing out a webapp (many long Clojure timers share this opinion). Clojure shines for web services that require lots of data processing in the server and for integrating with parts of the Java ecosystem.

<comment><USER8> I have not investigated Coast yet. I know it aims to be a Rails for Clojure... maybe it is, and maybe it would meet my needs.

But given the incredible power and expressiveness of Clojure, I find no reason to believe that the _best_ rapid web development framework could be developed in Clojure if the right motivated people attempted to do so.

I don't know how many people (Plataformatec?) were behind Phoenix, but even in its early versions it was comparable to Rails. In some ways, it was even better.

There seem to be two obstacles to doing this in Clojure. The first is that people who actually know enough about Clojure to do this are actually very busy (happily) doing Clojure for work. They don't have the personal need to build a Rails for Clojure. The second is that those who would be capable already know how to pick and choose the libraries and build their own (even better, more suited for the purpose) ad-hoc frameworks for their projects.

I suppose it could be a curse of the power of Clojure that the lack of language pain points lessened the need/motivation for experts to build their own RAD framework.

<comment><USER16> I'm not denying that something better than Rails can be built with Clojure, just implying that it doesn't exist, so for quickly pushing out a CRUD webapp multiple times without repeating yourself again and again(avoiding all the trivial/tedious stuff), there is Rails.

<comment><USER8> Yup, and that's why Rails is what I still use :). Phoenix was pretty great too, but its real benefit came from doing bigger back-end stuff on BEAM.

</comment></comment></comment></comment></comment></comment></comment></comment></comment><comment><USER17> We use pedestal+fulcro3+pathom

om.next was before that, but it seems to be almost abandoned, also fulcro author have solved a lot of depressing pain points of om.next.

Those three work like a perfect Lego.

<comment><USER4> I'm thinking of writing a project with a similar stack, is there any chance your code is open source? Also, what's your experience with Fulcro been like? Do you have any thoughts about it in comparison with other Clojure SPA libraries like re-frame?

<comment><USER17> Projects are closed source, so I can share only some general architectural examples.

Experience was like.. two weeks of hair pulling, gallons of coffee and no weekends, followed by intense relief and gratitude to fulcro author Tony Kay (also pathom author Wilker Lúcio) for all that not always obvious things which make great sense in the long run. This happened to me with several great Clojure things, so I immediately knew good experience was just around the corner.

Oh and his online book [http://book.fulcrologic.com/](http://book.fulcrologic.com/) has great general SPA insights.

Three pretty serious apps with fulcro so far.

</comment></comment></comment><comment><USER18> After some time with Clojure, I can not bear to look at _any_ OO code. It's like I developed an allergic reaction to class-based programming.

<comment><USER19> Even worse is having been through the enlightenment and then witnessing people talk about Javascript or Scala like it is still 1990. You just want to yell to them "You're all living in a cave!"

</comment></comment><comment><USER20> I gave a talk on using Fulcro for building web apps with Clojure.

[https://www.youtube.com/watch?v=PMbGhgVf9Do](https://www.youtube.com/watch?v=PMbGhgVf9Do)

</comment><comment><USER21> Navigating that slide deck was surprisingly frustrating. Clicking forward 10 times to get through a single slide must have been really annoying to present, too.

<comment><USER5> arrow keys seem to work ok.

<comment><USER22> Not on my tablet, trying to skim it at lunch.

Future consideration...

</comment></comment></comment><comment><USER23> Here is a link to the website of the library that they use, its pure chance that i was watching a talk with one of the creators of this library before i saw this at the top of hacker news.

[http://pedestal.io/](http://pedestal.io/)

</comment><comment><USER24> I love Clojure and take every chance to use it, but unfortunately it's very much behind the curve. Building web apps is more and more about tying together managed services with short scripts (aka serverless). This means that most app developers never have to deal with the hard technical problems that Clojure was designed to solve and Clojure's slow startup time on the JVM makes it unfeasible for serverless functions.

Clojurescript on Node could be a good contender, but last time I tried it, the development experience was very poor and the power of Clojure doesn't really shine in serverless functions, so I just use Python for that which is a perfectly adequate scripting language.

<comment> james-mcelwain > Clojure's slow startup time on the JVM makes it unfeasible for serverless > functions

GraalVM could totally change this.

<comment><USER25> Clojure uses too much runtime reflection. I tried many iterations of compiling different server projects with Graal and none worked. I could get simple programs to compile with an older clojure version, but nothing with recent code.

<comment> james-mcelwain I'd expect the tooling will improve over time. This obviously isn't an immediate solution for running Clojure in situations where cold starts matter, but in general I think many of the improvements coming to the JVM in the next few years will pay dividends for Clojure.

</comment></comment></comment></comment><comment><USER26> What I'd really like to see is a full stack clojurescript framework like next.js or meteor. I think fulcro comes close but it uses JVM clojure on the server side, so it's not entirely possible to re-use code on either end.

<comment><USER20> There are several commercial users of Fulcro using Node JS on the backend. I am one of them.

<comment><USER26> I had no idea about that, guess I need to dive deeper into the fulcro docs, thanks!

</comment></comment></comment><comment><USER27> Pretty simple Webapp that you could have done 7 years ago. That not necessarily a bad thing but I wouldn't develop a webapp with those tools.

Specifically the 'Component' library. I really didn't enjoy working with it and it one of the most complex to understand parts of our web application.

So while this seems like a fun set of slides (I have not watched the presentation yet), it's not what I would call a great introduction to Web development in Clojure overall.

<comment><USER28> What a surprise that the stateful edges of the application are the most complex! I didn't mind component in the past but we just started a project with mount and I really dislike working with that. Seems like there are a lot of ways to shoot your own foot with any of these libraries because there is no "one true way" to integrate them into an application. I haven't tried integrant yet but everyone and their dog seemed to be using it at the 2019 Conj.

I would totally start a project with pedestal today though.

<comment><USER29> Out of curiosity - what are the pain points related to Mount?

<comment><USER28> Its composability is a bit of a double edged sword. While it leads to a more declarative style of state management, I've found our implementation of it to lead to confusion about when /where/which states are swapped in or out. But honestly I think anyone can have a great or cruddy experience with any state management library depending on how it's weaved into the code, and I don't blame the library so much as I blame our implementation thus far.

</comment></comment></comment></comment><comment><USER30> Honest question, does anyone actually gain anything from reading slides without hearing the actual talk?

<comment><USER7> Honest answer: I feel like I did.

</comment></comment><comment><USER31> Clojure and Elixir (Erlang) are my favorite languages. When you get to the point where the parens and brackets just melt away and you have this awakening.

It makes me wish José (creator of elixir) would have chosen Clojure syntax instead of Ruby.

<comment><USER32> Have you looked at LFE?

[http://lfe.io](http://lfe.io)

</comment></comment><comment><USER33> I am more of Scheme guy and always feel Lisp is pretty overwhelming, but this looks quite clean. I like the little language for writing HTML.

<comment><USER33> But this looks like a sql injection awaiting to happen:

        (defn inc! [id]
          (kc/exec-raw (format "UPDATE articles SET count = count + 1 WHERE id = %s" id)))

(From [https://github.com/tbsschroeder/clojure-webshop- app/blob/mas...](https://github.com/tbsschroeder/clojure-webshop- app/blob/master/src/metro/components/db/articles.clj#L27)) You don't need format it seems: [https://github.com/korma/Korma/blob/master/src/korma/core.cl...](https://github.com/korma/Korma/blob/master/src/korma/core.clj#L518)

<comment><USER34> sanitizing SQL queries is just as simple in Clojure as in any other language (maybe more so), even if it wasn't done in this example.

<comment><USER33> It looks like it is builtin even in the library he uses. So not sure why he chooses format.

</comment></comment></comment></comment><comment><USER35> Is pedestal a better experience than luminus?</comment>


"Did Google Shutdown ____ Yet?" – App tracks status of Google's many projects - <AUTHOR> http://www.didgoogleshutdown.com <comment><USER2> This was interesting at first glance - it's very approachable in it's simplicity, and I can see it having an impact on the typical Google app user. Something like this could be a useful resource for people who may not think about the consequences of their dependence on proprietary cloud apps. I think most people don't think about the fact that Google (or any other cloud app provider) can and does shutdown their apps or significantly change the Terms of Service, usually with very limited options to migrate their data elsewhere.

FOSS cloud apps aren't subject to arbitrary shutdowns or unwelcome changes to the ToS. This is a huge, obvious advantage that most cloud app users don't realize. I think supporters of FOSS cloud apps should have something concrete to point to that shows the fragility of proprietary cloud apps.

However, I would not use this website as a reference for the following reasons:

\- No citations! It reads as if it is pure opinion without any citations.

\- It's hard to find evidence for some of the claims. Google+ shutting down? Is that pure speculation?

\- No place to discuss app status in the app. Comments or a wiki should be offered.

\- Closed source, no way to send pull requests for updates/corrections.

The page has a prominent link to the author's Patreon. This comes across as litte more than link-bait to draw traffic to the Patreon page, and a hit-piece on Google. The potential benefit to cloud app users gets lost.

(edit: formatting)

</comment><comment><USER3> Gmail is listed as dying. Did I miss a memo here?

<comment><USER4> >In a surprise move, Google has started moving people over to Inbox, a much less powerful app that was seen as another Google experiment.

I distinctly remember reading somewhere that Gmail interface was simplified and inbox was a much more powerful client.I cannot find that page right now.

<comment><USER5> They switched the default on me recently such that moving to Gmail now redirects me automatically to Inbox

</comment></comment></comment><comment><USER6> OpenID: Was removed to trick people to use G+ lol</comment>


Japan to add millions of new nodes to federated Nextcloud network - <AUTHOR> https://nextcloud.com/blog/japan-to-add-millions-of-new-nodes-to-federated-nextcloud-network/ <comment><USER2> Sounds impressive.

If Nextcloud continues to add features and get more traction, perhaps it can become a viable alternative to Google drive/mail/calendar?

Does anyone here have experience deploying Nextcloud in a business setting?

<comment><USER3> We are using NC with ~250 employees, works fine and runs smooth as butter, syncs to desktop well but many prefer to use the web interface. We are using LDAP auth, it powers our whole stack (Zimbra, OTRS, Debian/Ubuntu servers, Wifi, remote desktops, custom ERP, etc). Honestly, we have more problems with custom built software ($$$) than open source that is free for all. Sometimes I wish we could alter our internal workflows in a blink of an eye to leave out the greedy companies with whom we have software development agreements as legacy.

<comment><USER2> How well does calendar/contacts/email/docs syncing work with mobile devices?

<comment><USER4> Synchronizing calendar & contacts works great in my experience! I'm using DAVDroid for that.

</comment></comment></comment></comment><comment><USER5> Set up nextcloud on my home network and share stuff with friends and family that way, never got into federation but that's pretty awesome! Especially since it supports encryption and privacy in a pretty easy to use way.

<comment><USER6> Is encryption ready to use safely or is it still experimental?

<comment><AUTHOR> It is stable since v13 hit stable.

</comment></comment></comment><comment><USER7> Not to derail but I've been running ownCloud at home since 2013 and have considered switching since the fork but wanted to see Nextcloud mature a bit more. Any long-time ownCloud users have experience with switching and can offer advice or info on some of the pitfalls, if any? What are upgrades going forward really like with incremental updates and major version releases etc?

I often end up holding ownCloud updates back in apt as there's always this sense of dread that I'll have trouble getting the app out of maintenance mode. Versions 9+ have been better but upgrades sucked in the beginning even as a home user not using disk encryption.

<comment><USER8> I'm using ownCloud on one system and considering migrating it to another; should I switch to NextCloud instead? Seeking opinions.

For myself, my usage is small enough that I don't care if my "migration" is that I just copy over the two user's worth of data I have in the file sharing and set up the one shared folder I have again by hand. (It's a home cloud, not corporate.) In fact in some ways it'll be easier than what I was planning on doing.

<comment><USER9> try nextcloud.com/migration - but keep in mind that it is slowly getting harder and harder to switch. We try to keep it easy and smooth but ownCloud is backporting a lot of potentially breaking changes in their 'stable' branch, rewriting low-level code etc. Their engineers are of course new to the code base so they make, well, different choices than we would make :D

While feature-wise, we're still not really missing anything oC has, the underlying codebase is really diverging, we're not really merging any code from oC since a year now...

Migration will become a real, risky pita at some point I'm afraid. Apps are already dropping compatibility and mobile apps, too.

<comment><USER8> Thank you.

Like I said, a brute-force migration for me isn't too big a deal. Half the work for things like switching apps on my phone I'd have to do anyhow.

<comment><USER10> I just did a switch from oc 10 to nc 13. The docs work fine but are missing some potential table column additions (mostly with apps) which are needed to get things working smoothly. Thankfully the logs will tell you exactly what needs to be done.

</comment></comment></comment></comment></comment><comment><USER11> Hopefully this get implemented _extremely well_.

Anything else could make for some really terrible data breach possibilities. At scale. :/

<comment><USER11> Hmmm, NextCloud has a bug bounty program:

[https://hackerone.com/nextcloud](https://hackerone.com/nextcloud)

The maximum's seem pretty low though (to me), considering it's used for housing peoples personal data.

<comment><USER12> A bug bounty only helps with a very narrow set of security issues.

For instance, the deployment and updating process (which Nextcloud has no control over) is just as important.

<comment><USER11> Good point. :)

</comment></comment></comment></comment><comment><USER13> In the meantime, if you don't want to wait or don't live in Japan, there is the UBOSBox Nextcloud server appliance we announced yesterday: [https://indiecomputing.com/](https://indiecomputing.com/) (disclaimer: yes, my company)

</comment><comment><USER4> > Nextcloud servers are not alone. The Nextcloud Federation feature enables > users from one Nextcloud server to share with users on another server, > creating a globally spanning network of private, self-hosted clouds. A > federated cloud id, comparable to an email address, enables users to > identify one another […]

I wonder what domain they'll be using for these self-hosted Nextcloud instances. Are they going to allow for custom domains?

</comment><comment><USER14> Are all the component of NextCloud, including NextCoud Talk, open source, or are some features/components paid/enterprise/subscription only?

<comment><USER15> I don't know about any paid only plugin. Nextcloud is forked from ownCloud because the original founders of ownCloud didn't like the direction where ownCloud was heading (paid only features for enterprises) and they wanted to open source every part of it. They are unrealistically good people, making an unlikely good product :) See their reasoning of forking here:

\- [https://www.youtube.com/watch?v=UTKvLSnFL6I](https://www.youtube.com/watch?v=UTKvLSnFL6I)

\- [http://karlitschek.de/2016/06/nextcloud/](http://karlitschek.de/2016/06/nextcloud/)

\- [https://news.ycombinator.com/item?id=12919330](https://news.ycombinator.com/item?id=12919330)

</comment></comment><comment><USER16> This effort is to be applauded. Kudos to NEC and especially NextCloud; I wish them both luck!

</comment><comment><USER17> If these Nextcloud instances are being installed on routers then they likely won't have access to very much storage space.

<comment><USER18> Most routers support attaching a USB hard- or flash drive. This might become more convenient when they add Nexcloud to the router.

</comment></comment><comment><USER19> Meaning they're installing PHP on all routers to support Nextcloud? Not the expert here but that doesn't sound too secure to me.

<comment><USER20> PHP can be secure

<comment><USER21> Most people's "PHP is inherently insecure" perception comes from projects like phpBB 2.x circa a decade ago and the shared hosts (still?) running an ancient version of PHP.

<comment><USER22> And WordPress, drupal and honestly every other php project custom or open source.

PHP needs to go away.

<comment><USER23> Careful, there are a lot of WP, Drupal, and PHP devs here, and they make up a much bigger chunk of the front end developer pool than you'd expect post-2000s.

And from sitting in on a lot of leadership meetings, they're one of the few groups that perpetually seems to be concerned with something they depend on sunsetting.

As long as they're passing with ISO, I just stay out of it.

<comment><USER22> That's fine if they are upset. Php is a scourge on the internet. If php on the server and Java on the desktop were wiped out. The internet would be a better place.</comment></comment></comment></comment></comment></comment>


Ask HN: Studying for breadth - <AUTHOR> How have you gone about studying a wide range of subjects?
The main objective is to become conversant in any chosen subjects to the level where I would be able to ask sensible questions to experts and they would be able to give meaningful answers that I can understand.
A side objective, this being HN, is that this will make me better at spotting and evaluating entrepreneurial opportunities. <comment><USER2> If you are into studying textbooks, I recommend you take a look at the following article at LessWrong: The Best Textbooks on Every Subject - [https://www.lesswrong.com/posts/xg3hXCYQPJkwHyik2/the- best-t...](https://www.lesswrong.com/posts/xg3hXCYQPJkwHyik2/the-best- textbooks-on-every-subject)

</comment><comment><USER3> [https://books.google.com/talktobooks/](https://books.google.com/talktobooks/) This is great resource for studying breadth.

Also learn about generative design, it will help you get a feeling on what is a searchspace.</comment>


FCK DRM - <AUTHOR> https://fckdrm.com/ <comment><USER2> This is from gog.com The same company that forces you to install their game manager, which is DRM, in order to install an increasing number of games in their portfolio. The sequal to Hammerwatch is a good example of this. [https://www.gog.com/game/heroes_of_hammerwatch](https://www.gog.com/game/heroes_of_hammerwatch) It is all marketing.

<comment><USER3> You don't _need_ their download manager to download games. I'm able to download archives of all the games I have purchased from gog over https just fine.

<comment><USER4> I think they are referring to online play. You don't need galaxy to download, install and play single player, but an increasing number of titles are locking online play behind GoG Galaxy, if you want to play online you need to have GoG Galaxy running and logged into the account you purchased the game from.

Not saying it's a good/bad thing (Good: Servers need to be paid for. Bad: Why no peer to peer like the Good Old G̶a̶m̶e̶s̶ Days? (sorry couldn't resist)) just saying that's what they are doing.

<comment><USER2> Exactly that. The first version of hammerwatch supported local multiplayer. With port forwarding it worked extremely well over the internet. This wasn't an option at all, unless you first logged into their Galaxy program.

</comment></comment></comment></comment><comment><USER5> I agree that DRM is a bad thing. But proprietary software is also a bad thing. And GOG sells a lot of proprietary software.</comment>


US births decline for fourth year in a row, CDC says - <AUTHOR> https://lite.cnn.io/en/article/h_9454f4ed6f218afc194d33afddbab430 <comment><USER2> This doesn't seem sustainable, to me. Just basic evolution. As long as some subpopulation has a birth rate above replacement rate, that subpopulation will grow, until the total birth rate at least returns to replacement.

I feel like human culture has still not reached a steady state after the invention of birth control. I don't know what will happen per se, but it seems like the world of the future will have to be more encouraging of parenthood, in some way, than the world of the present. I hope it is a way that is consistent with the model of a modern free Western democracy.

<comment><USER3> Relevant article [1] and corresponding HN discussion thread [2]

Daily reminder that in an evolutionary context, the last 200 years are the blink of an eye.

I'll paste a comment I made there: "If an antibiotic doesn't wipe out its target, then its target's numbers will be devastated in the short-term, but in the long-term, its target will evolve immunity to the antibiotic and ultimately recover. If you think about it, contraceptives are extremely similar to an antibiotic whose target is human beings. We're still living in the short-term when the antibiotic seems to be effective."

[1] "The heritability of fertility makes world population stabilization unlikely in the foreseeable future" [https://www.sciencedirect.com/science/article/pii/S109051381...](https://www.sciencedirect.com/science/article/pii/S1090513817302799#bb0180)

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

<comment><USER4> > _If you think about it, contraceptives are extremely similar to an > antibiotic whose target is human beings._

We don't really know that. There are environmental stressors that lead a species to adapt; there are also stressors that cause a species to go extinct. I think time scales are really important here. Bacteria evolve much more rapidly than humans. But the rate of creating new antibiotics and contraceptives are probably in the same ballpark.

<comment><USER3> The newness of the contraceptives doesn't matter as long as they're still opt- in. No-one's suggesting humans will evolve condom-melting sperm. There's no need: a much easier trait to evolve is the desire to have kids.

<comment><USER5> But the "desire to have kids" is such and abstract and complex issue; nature already has it figured for us, we have the desire to have sex, to nurture and to like kids is secondary.

It would be impossible for nature to evolve such a complex, conscious yet instinct-like feature as "I want to have kids for the sake of kids... right, where do I start... I need a fit SEXUAL partner(so that I have healthy kids)... but just to have kids... totaly not for the pleasure of sex ... economy be damned, I want kids... kids are extremly hard to raise by modern standards... scratch that... I need to have kids no matter what".

<comment><USER6> > It would be impossible for nature to evolve such a complex, conscious yet > instinct-like feature as "I want to have kids for the sake of kids..

We have such an instinct now. Women (some men too, I guess) in their 30s frequently attest to a feeling that their "biological clock" is ticking and that they feel a yearning to have kids for the sake of having kids. This desire is probably still secondary to the raw sex drive in humanity, but evolution is _great_ at taking secondary drives and turning them up to 11.

Keep in mind also that evolution isn't necessarily genetic. Humanity's unique advantage is culture. We can change our "software" much faster than we can change our genetic "hardware". Some culture groups, e.g., the Mormons and the Amish, already have fertility rates very much above average. As long as fertility is heritable, it doesn't really matter whether the mechanism is genetics or culture: the future belongs to the people who reproduce.

<comment><USER5> Women have started having children throughout the aeons at a very early age. It is onĺy in the last 80.000 years that humans have made the conscious connection between sex and having children.

Womens fertilty declines sharply in their 30' and it is through conscious understanding of that fact and imitation that they think "their biological clock is ticking"; they consciously understand that it is now or never, that all their friends have children and that their looks and chances of attracting mates are fading.

Also, I'm willing to bet that people in the "my biological clock was ticking" camp have much, much lower birth rates than average(probably close to 1), which is an indicator rhat they actually felt pressured not to be childless rather than a genuine desire to have childreN.

I absolutely agree with your culture argument, I am just claiming that modern culture will go extinct unless we incorporate higher birthrates into it, not that the human species will go extinct.

</comment></comment></comment></comment></comment></comment></comment><comment><USER7> The article doesn't do a good job of highlighting that the decrease in pregnancy is mostly (maybe entirely?) among teenage girls. Maybe kids today are having less sex or maybe they're better at using birth control. Either way, this is a good thing.

<comment><USER8> Why is teenagers having less sex good?

<comment><USER9> Less unwanted pregnancies which result in less abortions, single mothers relying on taxpayer social safety nets, or extra state money spent on kids falling through the cracks of the foster care system.

<comment><USER10> The problem here seems more unwanted pregnancies than with teenagers having sex.

I se how less sex is an easy solution to the problem, but it is also the wrong one. Your teenage years are when you have the more energy and hormones, you are basically built to have sex. Not to mention it's healthy for the mind and body.

It would be like not allowing teens ride bikes because of possible crash with cars since stats show teens are more likely to have accidents than adults.

Better find a way to limit the accidents themself: you get healthy kids, having fun, and they grow into better adults.

<comment><USER9> A big part of the stigma around teen sex is rooted in thousands of years of religious taboo associated with it among the world's major religions. This is likely because those belief systems were the original dominant form of birth control.

This is likely a case where the evolution of human culture hasn't caught up with the available medical technology.

</comment></comment></comment></comment></comment><comment><USER11> I am a PhD with 5 kids under the age of 10, people think I'm crazy.

My new thing is telling people I have 10 kids, then saying 'just kidding, only 5'

<comment><USER12> You're a beginner. I have 6 kids under the age of 10, and another 6 aged 10 and older. Not kidding: only 1.2 dekachildren.

You have some catching up to do.

</comment></comment><comment><USER13> The best book I've read on population is Countdown by Alan Weiss [https://www.amazon.com/Countdown-Last-Best-Future- Earth/dp/0...](https://www.amazon.com/Countdown-Last-Best-Future- Earth/dp/0316097756). If you think we need to grow or that leveling off to 10 billion or even 7 billion helps, you'll appreciate reading the book.

Among other points, he recounts several nations that have lowered birthrate without coercion to greater abundance, prosperity, and joy -- Thailand, for example.

It inspired me to 3 podcast episodes on lowering birth rate: episodes 248, 250, and 251 [http://joshuaspodek.com/guests/rants-raves-and-monologues- vo...](http://joshuaspodek.com/guests/rants-raves-and-monologues-volume-9).

Also Limits to Growth's 30 year update [https://www.amazon.com/Limits-Growth- Donella-H-Meadows/dp/19...](https://www.amazon.com/Limits-Growth-Donella-H- Meadows/dp/193149858X)

</comment><comment><USER14> i can only really see this as a good thing, but im admittedly a bit of an antinatalist myself

</comment><comment><USER15> Population change is going to have wide-ranging effects on society and the economy. Already, the shrinking size of generations is putting smaller colleges out of business and is expected to hit the housing market hard in the near future [1].

Immigration will have somewhat of a mitigating effect, but sentiment has been pretty anti-immigration for a while. Worse, the rest of the world is experiencing the same decline in birth rates [2], and is developing so fast that the economic argument for a resident of another country to emigrate to the West is shrinking. (Why learn another language to live in Denver, when Shanghai is faster-growing and more modern? [3])

To be sure, there are lots of confounding factors, like the universities and social freedoms available in the West, but on a 50-year span we should expect to see some dramatic shifts due to these demographic evolutions.

[1] [https://www.wsj.com/articles/ok-boomer-whos-going-to-buy- you...](https://www.wsj.com/articles/ok-boomer-whos-going-to-buy- your-21-million-homes-11574485201)

[2] [https://amp.scmp.com/news/china/society/article/3039064/chin...](https://amp.scmp.com/news/china/society/article/3039064/chinas- ageing-population-prompts-plan-deal-looming-silver-shock)

[3] [https://a16z.com/2019/10/30/the-power-of-qr- codes/](https://a16z.com/2019/10/30/the-power-of-qr-codes/)

<comment><USER16> Ironically (given our current Zeitgeist) by the time we start to feel the effects of the these demographic trends, we'll need more automation to keep up productivity (and therefore long-term GDP growth)... especially when one considers the entitlement spending that will be needed to care for the elderly).

I'd imagine that by then, there will be more individuals advocating for increased automation and (hopefully) society will become increasingly 'techno- optimist' as a result

</comment></comment><comment><USER17> Here's a comparison to the rest of the world: [http://worldpopulationreview.com/countries/total- fertility-r...](http://worldpopulationreview.com/countries/total-fertility- rate/)

This is an interesting topic for a number of reasons. It's tied up in political questions like immigration, taxes, healthcare and education. And there are unresolved economic questions like, "how will capitalism survive the end of endless growth?" Sociological questions like, "why did everyone stop having babies?" And then there's the environmental perspective, "Are we already hopelessly past this planet's carrying capacity?"

</comment><comment><USER18> The earth resources are stressed beyond the breaking point with the current population.

A declining population is not a problem - except to handwringing economists.

From a human perspective, we need to only have workers to fulfill the production needs of society.

Paying for retirees is solvable by simply aggressively taxing the billionaires.

In the US, having a kid or kids is an unaffordable luxury item for couples trying to survive in today's economy.

I know the only way, I can afford my kids is that I got lucky with the stock market.

<comment><USER16> Earth's resources are strained, yes. However, taxing billionaires as you propose wouldn't necessarily pay for all the entitlement spending that the elderly require.

A solution to both of these problems is increasing total factor productivity (aka doing more with less). The big rise in living standards during the post- war boom was largely a result of a huge increase in total factor productivity.

This has petered out since the 1970s and a lot of the 'zero-sum' mentality/nostalgia for a 'Great America'/fighting over a fixed economic pie in the US today is because we haven't been increasing productivity (i.e. there hasn't been _enough_ technological innovation and disruption) at a fast enough rate.

<comment><USER16> Cheatsheet source:

[https://en.wikipedia.org/wiki/Total_factor_productivity#cite...](https://en.wikipedia.org/wiki/Total_factor_productivity#cite_note-1)

For the adventurous/curious:

[https://www.bls.gov/dpr/faqs.htm](https://www.bls.gov/dpr/faqs.htm)

[http://www.helsinki.fi/iehc2006/papers2/Warr.pdf](http://www.helsinki.fi/iehc2006/papers2/Warr.pdf) [PDF]

[https://assets.cambridge.org/97811070/36161/frontmatter/9781...](https://assets.cambridge.org/97811070/36161/frontmatter/9781107036161_frontmatter.pdf) [PDF]

</comment></comment></comment><comment><USER19> Shame. I wonder where we fall in the saga of the collapse of the Roman Empire?

<comment><USER20> Other than in general terms, there's no comparison.

The birth rate declining is normal in terms of industrialized countries... people educated enough to use birth control and who have availability tend to have fewer kids. The rest of the world hasn't caught up yet, and probably won't in time to avoid problems.

The birth rate isn't declining because "America is in decline"... it's declining because people are choosing not to have children. The wisdom of that choice is open to discussion, of course.

<comment><USER19> Richness becomes childlessness, which becomes poverty, which becomes death.

</comment></comment></comment><comment><USER21> Having a kid is hard and usually looks unrewarding from the outside in the US. I get that having a kid isn't for everyone but for a lot of working class people the optics look like a choice between having a belligerent room mate that takes all your money vs. being able to poonhound around on Tinder and blow my money on fun. Some people might choose the former if the outcomes weren't so starkly contrasting. The government needs to be doing more to support families or else we're going to end up in a situation like Germany where we have to import people from abroad just to prevent shrinkage.

<comment><USER11> There are over 100,000,000 south of the border who have indicated they would like to come to the U.S.

</comment></comment><comment><USER22> Do you think some of this has to do with climate change, I mean right now, who really feels like bringing a child into this world is a good idea ?

I'd personally be quite hesitant at this point.

<comment><USER23> question : at what point in modern history would you have been comfortable doing so, if you aren't now?

The world is getting progressively safer, by the numbers.

<comment><USER22> I feel like through all the worst times in the world, there was At least a relatively safe guarantee the biosphere would be there to support you.

We're destroying that like never before so I think that it's a much worse time for our future prospects personally.

No other thing worries me more right now than climate change.

Having a habitat to live in is important, it might be easy to forget that we're animals too but I think as we look around at the extinction at other species via our smartphones, we don't realise this is our future too if the current trajectory doesn't turn around very, very fast.

</comment></comment></comment><comment><USER24> When will the narrative that "there are too many people" finally catch up to the facts?

Edit: Just pointing out that doomsday predictions about population growth have been consistently wrong for the last 100 years.

<comment><USER25> What are the facts?

<comment><USER24> [https://en.wikipedia.org/wiki/Projections_of_population_grow...](https://en.wikipedia.org/wiki/Projections_of_population_growth)</comment></comment></comment>


Andrew Binstock: Use More VMs  - <AUTHOR> http://drdobbs.com/tools/229402296

<comment><AUTHOR> The article touches on the idea of using VM's for surfing the web - <USER2> I already do to a limited extent by having a virtual machine dedicated to logging onto Facebook once it became socially necessary.

I also have VM's set up for various non-programming projects. It is great to be able to come back to something I am working on after a couple of months and have nothing changed - all the relevant windows open, all the relevant files handy, etc. without having to remember what I was thinking when I was deep into it all that time ago. This has set me to wondering if the desktop OS of the future is a hypervisor - in a sense Windows 7 Professional is a step in this direction with the built in version of XP.</comment>


We Are Not Living in a Simulation. Probably - <AUTHOR> https://www.fastcompany.com/40537955/we-are-not-living-in-a-simulation-probably <comment><USER2> The authors talk about the possibility of replicating the universe rather than simulating it. They conclude that it is not possible to replicate, but I don't think that conclusion has much value. If it were possible to replicate digitally the universe with resources less than those of the entire universe, that would suggest that it is possible for the actual universe to exist in a simpler form. Occam's razor would then suggest that the real universe would simply take that simpler form. So if the universe is as simple as it can be, retaining all its currently observable properties, then it follows that is inherently un-replicable. Or, put another way, the universe is its own replication.

Simulation is another matter. Simulation by its nature cuts corners. Otherwise why bother? The challenge of the game of deciding if our universe is a simulation is finding a way to spot the shortcuts taken in the simulation.

<comment><USER3> Occam's razor cannot be used to assert that when something exists, if must be or indeed is likely, to be in its simplest possible form. Human DNA has plenty of redundant areas and yet we still exist. Indeed, probably all organism have a non-simplest form of DNA and yet still do just fine. We only have one example of a universe and even for that we have an imperfect understanding of its working. It is therefore impossible to know or assert that the universe is it its simplest possible form.

<comment><USER2> By form I don't mean physical form of objects in the universe, but the form of physical law which describes all observable events which compose the universe. That that form is the simplest it can be is exactly what Occam's Razor suggests. It is that form that must be grasped in order to assess the difficulty of replicating the universe in digital form, which is the topic of the linked article.

Neither I nor Occam _assert_ that the universe is in its simplest possible form, Occam suggests that is the likeliest assumption, and so far he's been on the money. Reasoning from other assumptions would require extraordinary evidence.

People do use Occam's Razor to reason about the nature of the universe. Here is a reference to an argument that the Bohm-DeBroglie interpretation of quantum physics is incorrect because Occam's Razor: [1]

[1] [https://en.wikipedia.org/wiki/De_Broglie%E2%80%93Bohm_theory...](https://en.wikipedia.org/wiki/De_Broglie%E2%80%93Bohm_theory#Occam's-razor_criticism)

</comment></comment></comment><comment><USER4> fwiw - this article was worth glancing at just to get the link to the debate on the subject hosted by Neil deGrasse Tyson : [https://www.amnh.org/explore/news- blogs/podcasts/2016-isaac-...](https://www.amnh.org/explore/news- blogs/podcasts/2016-isaac-asimov-memorial-debate-is-the-universe-a-simulation)</comment>


Former Nokia CEO Elop Leaving Microsoft - <AUTHOR> http://www.theverge.com/2015/6/17/8796613/jo-harlow-leaves-microsoft

<comment><AUTHOR> And Jo Harlow is out too.

As a Nokian, I've been waiting for this day for years.

If you've never seen a Finn smile, today might be your lucky day.</comment>


The One Score That Can Improve Your Writing with a Single Click - <AUTHOR> http://www.jamesaltucher.com/2015/04/the-one-score-that-can-improve-your-writing-with-a-single-click/ <comment><USER2> It's funny how the title of this story, in optimizing for F-K score, looks exactly like most internet clickbait, but I suppose that isn't a coincidence.

I myself have found this to be a large problem in my writing. I'm an on and off writer for a corporate newsletter that my company distributes internally, and at this point I include online F-K score checks into my drafting process. This isn't a humble brag or anything, I actually think many technical people aren't able to express themselves well due to writing in a way that is very hard to intuit.

(comment f-k score is 12, btw)

</comment><comment><USER3> In case anyone is wondering, this is the specific formula:

        def KincaidGradeLevel(syllables, words, sentences):
            return 11.8*(syllables/words) + 0.39*((words/sentences)) - 15.59

</comment><comment><USER4> TLDR: write at a lower grade level for more appeal.

It's a sales pitch for what seems like a multi-level direct sales marketing scheme dressed in a marketing copywriting school. The post is bait; the hook is the link at the bottom.</comment>


Leave your cellphone at home - <AUTHOR> http://nplusonemag.com/leave-your-cellphone-at-home

<comment><USER2> tl;dr ?</comment>


Why we made a computer game about the federal budget - <AUTHOR> http://www.brookings.edu/blogs/up-front/posts/2016/04/26-why-we-made-a-computer-game-about-the-federal-budget-wessel <comment><AUTHOR> See also, _How we picked the debt goal for The Fiscal Ship_

[http://www.brookings.edu/blogs/up- front/posts/2016/04/27-how...](http://www.brookings.edu/blogs/up- front/posts/2016/04/27-how-we-picked-the-debt-goal-for-the-fiscal-ship-wessel)</comment>


Vox Media preparing round of layoffs as business fails to improve - tech-historian https://www.cnbc.com/2020/07/14/vox-media-preparing-round-of-layoffs-due-to-coronavirus-business-impact.html <comment><AUTHOR> If woke clickbait a la Vox does not work in these times, I can't imagine other media companies with the same business model surviving for long.</comment>


Redrawn Electoral College Map With 50 Equal Populations - <AUTHOR> http://www.fakeisthenewreal.org/reform/ <comment><USER2> Earlier submission of link to Atlantic blog discussion of same map:

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


Ubuntu 17.10 is a disappointment and installing it is a regret of my life - <AUTHOR> https://www.reddit.com/r/Ubuntu/comments/78i3mr/ubuntu_1710_is_a_disappointment_and_installing_it/ <comment><USER2> This seems a little premature and more than a little histrionic.</comment>


Iiith Alumni's Reimagining Online Tech Education with Their Startups - <AUTHOR> https://blogs.iiit.ac.in/scaler/ <comment><AUTHOR> From IITH batchmates in 2010 to startup founders of InterviewBit & Scaler Academy, they've come a long way.

Here's a glimpse of how they started off and are pursing their dream of revolutionizing online tech education.</comment>


Man Plans to Retire to Holiday Inn Instead of Nursing Home Because It's Cheaper - <AUTHOR> https://www.distractify.com/p/retire-to-holiday-inn <comment><USER2> This is ridiculous because a nursing home and the Holiday Inn are not remotely comparable. A nursing home is for people who can't take care of themselves. They have nursing staff available 24 hours a day. They assist people with going to the bathroom, eating, taking medicines, etc. A Holiday Inn does none of that.

Clearly this man is capable of taking care of himself, which is great. He doesn't even need assisted living. He would fare just fine in a regular retirement community or just in a regular apartment, so the question is not how a Holiday Inn compares to a nursing home. It's how a Holiday Inn compares to an apartment.

<comment><USER3> Eh, it seems like a nice solution for people in a middle case. If you aren't in bad enough shape to need constant medical attention, but aren't quite up for the cleaning and maintenance requirements of a regular apartment, you can live pretty nicely and not spend too much money.

Suppose it also helps if you only really want to have a suitcase or two worth of possessions.

<comment><USER4> I would think hiring a cleaning person (and handyman maybe?) would be cheaper

</comment></comment></comment><comment><USER5> Everything old is new again. It used to be common to live in hotels, specially towards the end of one's life, at a time where specialized facilities were scarce or nonexistent. Just off the top of my head Tesla's last years were spent at the Hotel New Yorker, with Westinghouse footing the bill.

</comment><comment><USER6> Even before you retire, if you are single or just a small family it is far far cheaper and far far better to live in a Holyday Inn than an Apartment building. First they will give you monthly rate instead of daily rate which is half. Then you have no deposit. You interact with hotel staffs who treat you like God instead of a landlord who treat you like slave. You need not clean the room or bed. Officially you occupy a small area though, your bedroom and bath, but you have the whole Hotel facility and area to share, you can also visit the city parks and libraries.

<comment><USER7> What city do you live in where hotel rates, even at half, are far cheaper than apartments?

<comment><USER8> A 1 bed flat in zone 1-2 London is approx £1500 a month. Call that £50 a night?

I think it is pretty rare to see a similarly located London hotel < £100 a night. Certainly i have airbnb'd for ~55-60 comfortably - but with way less personal space.

For my city, at least, i dont think it would be cheaper but if the monthly rate thing is true can imagine it being similar order of magnitude?

<comment><USER9> At the hotel you're not paying utilities and are getting free breakfast every day. How much is weekly maid service in London?

<comment><USER8> The cheap end of hotel rates dont include breakfast. You are right on utilities, but the counterpoint is that you have (for example) lost access to a kitchen to cook, pushing other costs up.

I reckon costs being of "similar magnitude" is plausible (if the monthly rate discount is truly ~50%). Interesting trade offs imo

<comment><USER10> When we stayed at an extended stay, there was a stovetop and a microwave. I'm sure if you wanted to cook you could get a hot plate.

</comment></comment></comment></comment></comment></comment><comment><USER11> I'm going through this with my father. Since he didn't buy a long term care plan, the assisted living facilities by us will be $11k a month out of pocket.

If you live in the USA, please talk to your parents/spouse/friends about long term care.

<comment><USER12> Not sold on LTC. That's great if your goal is to live in a facility some day. But hopefully I never have to. Can downgrade from big house to maybe a smaller condo over time. Take care of myself so hopefully will end up OK.

If not? I get checked into the same home as a LTC user with Medicare. I pay for it until I am broke, then Medicare takes over.

I really don't see the upside. In the case I have a large estate and need LTC, the LTC insurance protects my estate so I can pass more of it on. But as not a huge fan of generational wealth, I see no benefit to me or the world to buy LTC insurance. In fact, less money to enjoy now or grow my estate.

<comment><USER13> Medicare won't pay for assisted living, but you can use your social security money towards it. If you can't pay, and you can't take care of yourself then Medicaid kicks in, your social security gets taken and you go to a nusing home.

<comment><USER12> Yah so at that point you are living out your days in a home. So not seeing how the long term care insurance mattered.

</comment></comment></comment></comment><comment><USER14> > If you're thinking he's overlooking the care one gets in a retirement home, > he's considered that as well, and feels confident the staff of Holiday Inn > are up to the task.

Having lived out of a suitcase at a competitor's inn for 3 years on a job out of town I think Planning Man is in for a care let-down. Or if dementia sets in, perhaps not.

</comment><comment><USER15> This is really no different than the huge number of older retired people who move to foreign countries. Expats. Obviously, not for everyone as it is quite different and sometimes challenging to live in a foreign country.

As someone who has moved to SE Asia (Vietnam) and is 'only' 45, I think almost daily about how much money I'm saving for my eventual 'retirement' and how much happier I am.

<comment><USER16> > As someone who has moved to SE Asia (Vietnam) and is 'only' 45

How did you cope with the loss of (connection to) friends/acquaintances/possibilities/family/children? They can't be dead with 45.

<comment><USER17> You build new connection.

<comment><USER18> Other expats? Or learn Vietnamese and make friends with locals?

<comment><USER17> Whatever you prefer.

</comment></comment></comment></comment></comment><comment><USER19> As someone who's facing this with his parents. Sadly, it's true. Nursing homes prices have tripled over the last five years.

<comment><USER11> The nursing and rehab center my dad is currently staying costs $700/day. That's what I paid for Sandals Jamaica for my honeymoon, an all-inclusive all you can eat/drink resort.

<comment><USER20> A quarter million a YEAR? It's a wonder there's any inheritance left...

<comment><USER10> I'm not optimizing our lives to leave an inheritance. The optimum scenario is to spend our last penny on our last breath and leave nothing for our kids.

We took care of them growing up, we gave them the advice and financial backing to help them get their lives off to a good start. It's up to them to not mess that up.

I've told my parents the same thing - I am an only child. They should enjoy their lives to the fullest and not worry about me. We've had discussions that they brought up. They know I'm not keeping the house and I am going to sell it as quickly as possible if they pass and not worry about optimizing what I get out of it. I've done the real estate thing before. It's a headache when you live close by, let alone when you are a hundreds of miles away. They know we aren't keeping anything in the house besides the pictures.

They have long term care insurance, but if they didn't and it meant selling the house to qualify for Medicaid - so be it. They said it is just "stuff".

My parents are in their 70's and they both retired in their mid 50s when they were both healthy enough to enjoy themselves. They are still relatively healthy today. They didn't have millions in the bank. My dad was a factory worker and my mom was a school teacher.

<comment><USER21> Did they have solid pensions? That's like having lots and lots (and lots) of savings.

<comment><USER10> My mom had the standard teacher's pension which I believe is 60% of your last years salary. Assuming she made 60K a year at retirement that is like 900K savings at a 4% withdrawal rate. My dad had less than a million in savings.

Of course she did have guaranteed access to health care insurance. My dad has less than a million.

</comment></comment></comment></comment></comment></comment><comment><USER22> Similar idea with cruise ships [1].

In Australia this largely seems to work better. There's obviously public aged care but that can be a crap shoot in many ways. Like there might only be a place for you 200 miles from where you'd been living, which might be a challenge to maintain contact to friends and family. But if you have some capital behind you (eg you own your house and sell it) then you have private options, which tend to be a lot better. Typically, you pay a "deposit" (for lack of a better word) and then the facility collects 85% of your aged pension. When you die, your deposit is returned to your estate. The size of that deposit varies a lot. It might be as little as $300k or it might be $1m+. It depends on what you want.

The whole thing seems a lot less "gougey" than what I know about aged care in the US, for example.

[1] [https://www.aplaceformom.com/blog/2013-2-2-cruise-ship- retir...](https://www.aplaceformom.com/blog/2013-2-2-cruise-ship-retirement- assisted-living/)

</comment><comment><USER23> I'd seriously look at retiring on a cruise ship. Might not be as cost effective, but it would give you a ton of stuff to do. I could probably live on a cruise ship for less than what it costs me to live.

<comment><USER24> How is there more stuff to do on a cruiseship than on mainland?

<comment><USER25> What if we tweak it to, "More stuff to do within (walking/assisted mobility device) distance of your personal living quarters?"

There are assisted living residences in urban areas, of course, but even then you may need to use public transit or taxis to get to all of the activities you enjoy.

I doubt the statement is always true, but it feels like it might be true enough of the time for it to be worth a "Hunh, that's an interesting conjecture to explore."

</comment></comment></comment><comment><USER26> Our generation of people, millennial, have no hope of having the same retirement as people in their sixties today.

Simple arithmetic says that once the taxpayer/dependent ratio will hit that of Germany, it will be very very hard. Either you have a very strong industrial economy, or you study Greek.

Having some kids, and expecting them to give back one day does not seem to be anything unnatural to me. Though, I hope I will get some humility by then, and not have them bail out me financially by my fifties as my own parents did :(

<comment><USER27> That is why it is important not to solely rely on W2 income. Income has to be supplemented by starting side businesses in order to actually save and invest for anything without falling for the illusions of debt. On top of moving to places more affordable, it _might_ be possible for the average person to retire. I just doubt that employment and a 401k are going to do that on their own. All the modestly wealthy people I know have other sources of income besides their main job.

<comment><USER10> Because the majority of businesses don't fail in 5 years....

<comment><USER27> Just because a lot of people fail at it doesn't mean that those who might want to take the risk shouldn't be made aware of the benefits. I would personally rather deal with failure for the shot at making more income. It's not for everyone, and they can certainly stay on the beaten path and do just fine. (so long as their debt doesn't spiral out of control) I'm not saying that people should dedicate their lives to home businesses, but they can try different things on the side to see what works with a minimal risk of catastrophic failure.

<comment><USER10> If you are a software developer in any major city in the US and you're just really good at your bog standard enterprise developer type jobs or yet another software as a service CRUD app developer, you're already probably in the 80th income percentile. If your goal is increasing net worth, it's quite easy to live a comfortable middle class lifestyle and still put aside enough to have a couple of million and a paid off house in 15 to 20 years just by putting money in an index fund.

There is really little risk of being long term unemployed as a software developer if you keep your skills in line with the local market and keep your network strong. This is coming from being a developer for the past 20 years. I'm not talking about how much I have personally saved, just how easy it is to get a job or at least a contract. It's even easier for dual income earners. You can literally save an entire second income or put it toward net worth building.

On second thought, the best "investment" I guess is a working spouse and a happy marriage. Statistics back that up.

<comment><USER26> With all respect, this logic fails to account for the rising taxpayer/dependent ratio.

If American tax rates will reach that of Europe, even dual income high earners, will just break the comfortable level — way less what I deserve with my position in society. And even that will worsen further over time.

At some t/d ratio, the nation will simply turn into a "transfer economy" — when cash value of all pensions/savings withdrawals/welfare/rents will begin closing on on the total income of working populace. That's something close to what we had in Eastern Europe when Bloc collapsed.

You don't realise the severity of issue until you calculate that NPV of an average boomer generation person, might've been higher 40 years ago, than NPV of savings and future contributions of highest earning young people today.

<comment><USER10> I'm going to repeat a previous argument in a way that hopefully doesn't get my hand slapped and my comment flagged:

There is an easy answer to that: a pro immigration policy for both high skilled labor that creates a jobs by starting businesses and low skilled labor that can do the work that our native born society is too old to do.

<comment><USER26> You think that can happen with this political climate?

And people don't immigrate to economically unsuccessful nations.

<comment><USER10> In the current climate - no.

We could have a progressive (not politically/mathematically) immigration policy to keep the number of workers/retirees in the right ratio.

</comment></comment></comment></comment></comment></comment></comment></comment></comment><comment><USER28> I read this story a few weeks ago. Don't know if it's fiction or not [https://www.reshareworthy.com/old-lady-alone-on-a-cruise- shi...](https://www.reshareworthy.com/old-lady-alone-on-a-cruise-ship/)

</comment><comment><USER29> It's interesting that anything paid for with funny money, like loans, the sale of one's nest egg, or insurance, is wildly overpriced.

</comment><comment><USER30> I can't tell whether this is satire or April Fools material or not, and that's a little bit sad for the way we treat our seniors.

</comment><comment><USER31> Reminds me of this

[https://m.youtube.com/watch?v=-dWFKp- bJtk](https://m.youtube.com/watch?v=-dWFKp-bJtk)</comment>


Ask HN: How do you backup your Mac? - <AUTHOR> Four months ago, the hard drive of my MBP went dead, I was lucky that just have a backup using Time Machine so I got most of my files back. But there is no backup now (the drive used as Time Machine is also dead), worried.<p>Guys, how do you backup your Mac, iCloud, Time Machine, or any third party solution? <comment><USER2> Time machine to hard drive plugged into my AirPort Extreme, BackBlaze and iCloud for files.

</comment><comment><USER3> I'm using a Synology DiskStation for Time Machine and Windows backups.

<comment><USER4> same here</comment></comment>


White – Easy UI Automation for applications on Windows (for now) - <AUTHOR> https://github.com/TestStack/White

<comment><AUTHOR> Before i forget, you can find a quick intro on how to use it here : [http://www.codeproject.com/Articles/289028/White-An-UI- Autom...](http://www.codeproject.com/Articles/289028/White-An-UI-Automation- tool-for-windows-applicatio)</comment>