Hacker Newsnew | past | comments | ask | show | jobs | submit | yumaikas's commentslogin

That is one of a couple syntactical shorthands, explained a small bit here: https://nova-lang.net/introduction-to-nova/sight/#sometime-y...


(Nova dev here)

Nova's execution model is a lot friendlier to implement vs Prolog, for one.

One big reason reach for Nova are when I have something -very- state-machine shaped. It is quite good at that.

I'll try to come back later with more explanations


When you say "friendlier" does that also mean "less powerful"? Prolog's execution engine is very capable, so does Nova give up some of that power in exchange for friendliness or does it somehow retain it?


Depends on what you mean by power, I suppose. Nova is Turing complete, so there's that.

One big difference between Nova and -most- logic languages is that "forgetting" things is a normal part of operation. Nova is also forward chaining, rather than backtracking.

The end result ends up with Nova programs being something closer to an interpreter in a lot of cases, and writing inputs for said interpreter.

So, Nova doesn't do as much on your behalf as Prolog does, deliberately trying to be easier to reason about, and to have more predictable performance characteristics.


I think the focus on the state machine may be the problem. I don't know much about prolog, or why it doesn't really enjoy more status in the programming world, but I suspect that while it is good at repesenting states, it is not very useful for writing programs...

Case in point, the pong programs. Looking at the impl, vs a <50 line js impl, this looks more like an assembly language for state, not necessarily something that makes state more visible or readily apparent...

Having a nice dialect for a (is this formally provable?) state machine is nice, but I'm not convinced founding the language from state machines is the correct approach vs merely using a fluent library e.g. https://stately.ai/docs/xstate

Not saying that I'm correct, but would be interesting to hear more of the philosophy of why Nova, vs just a simplisitic implementation of some card game rules...


Onion creator here, happy to answer any questions!


I've been working on https://deja-vu.junglecoder.com which is an attempt to build a JS toolkit for HTML-based doodads that shares some ideas with this.

I don't quite have proper reactive/two-way data binds worked out, but grab/patch seem pretty nice as these things go. Also, the way this uses templates makes it very easy to move parts of the template around.

It's also largely injection safe because it's using innerText or value unless told otherwise.


In the GMTK game jam, there was a -dramatic- shift usage towards Godot from Unity this year


Location: Denver, CO

Remote: yes

Willing to relocate: No

Technologies: C#, ASP.NET, React, Typescript, JavaScript, HTML, CSS, Tailwind, Godot, Lua, Elixir, Powershell, git, Golang

Résumé/CV: https://junglecoder.com/downloads/Resume/AndrewOwenFullstack...

email: yumaikas94@gmail.com


They are fairly generalizable, to a point.

The thing about Erlang behaviors is that they rely on several other pieces of Erlang to work well.

One big one is being able to be notified when another process goes down, or is aborted.

The other big one is being able to reason about state in the face of such failure.

Erlang decided to go with immutable data structures, shared nothing processes, and the OTP behaviors generally expect you to decompose the behavior of the various bits into functions that represent a single atomic step.

The more of those properties that you don't share with Erlang, the harder it will be to adopt OTP style semantics in your system.


The other thing about behaviours is... Especially if you have a synchronous API, you can mock it with a stateful system, for example calling out to a GenServer or calling over the network. This is why GenServer.call doesn't emit an error tuple; an network or interprocess error by default is considered to be unrecoverable. In most other systems you'll fumble around with colored functions transitioning between a sync system or async call, or, have to do annoying error handling, or even worse stack unwinding with an exception or get stuck in a panic.

In Erlang, a sync API behavior can safely have a failable async implementation, and that is powerful


So, the big difference between Go and Erlang style concurrency is that go style concurrency doesn't give you a readily available reliable way to keep an eye on other goroutines, as I understand it, where there are mechanisms in Erlang (links and monitors come to mind) to help accomplish that, and, in fact, it's one of the core parts of the Erlang model of concurrency


It does not give you a way to reliably track arbitrary goroutines that "this" goroutine (for whatever that may be) wants to track, the way an Erlang process can just "link" to anything it is capable of naming the PID for.

However, you can construct a reliable mechanism where one goroutine can start another and know whether or not the one it started has failed by using the available primitives, as I did in https://github.com/thejerf/suture . It's an easier problem since there's no cluster and no network that can get in the way. I've also done the exercise for the network case: https://pkg.go.dev/github.com/thejerf/reign#Address.OnCloseN... but that only functions within the network defined by that library because, again, it just isn't arbitrarily possible.

(I suppose it's relevant to some of my other comments to point out that I've also implemented basically Erlang-style concurrency in Go, with network, but as a relatively idiomatic translation rather than a blind one.)


Where would you use this? Most languages have good enough string processing to imitate a lot of what AWK does


I mean, a lot of people may not have the financial option to have had kids younger. Like, the last 15 years have included two "completely upend your life" level crises, along with a lot of smaller crises that could have swept up someone.


I dunno, kids may be incompatible with a lot of lifestyles, but I wouldn’t call them inherently expensive. You just have to adjust your expectations.


I dunno how you can say that. When children are young you have two options:

- both parents work, you pay for childcare

- one parent drops out of the workforce, takes care of children at home

neither of these is cheap. Decades ago it was realistic for one parent's salary to cover the whole family but these days salary stagnation and increased costs of e.g. housing makes it much more difficult.


No. Absolutely wrong.

Homes are much larger now than in 1955. Cars are being purchased with far more (expensive) features, and they are driven for fewer miles before being "upgraded". We eat out much more. Even when we eat in, we eat more luxurious meals. We buy Frappuccinos daily, we buy clothing much more frequently, we impulse shop significantly more, we utilize medical services much more frequently, we take far more, and more luxurious vacations, we rack up ludicrous levels of student debt for degrees that have no hope of servicing said debt, etc, etc, etc.

We are wealthier today than at any point in human history. The myth that all homes must be two-income is predicated on the outrageous lifestyles we choose, NOT due to anything inherent in "society" or "the economy".

Our insane consumerist appetite is what's preventing one household member from staying home, nothing else.


I'm going to seriously disagree with your depiction:

- frankly fraps, daily, are a magnitude of order smaller than childcare. You could deprive yourself of a frap every day for literally years, and you still couldn't afford even 6 mo of daycare.

- we need to buy clothing more frequently because our clothing quality is shit, and the good clothing quality has increased in expense

- if you think adult humans consume medical services too often you're in for a fucking shock of your life when it comes to babies, which being pregnant is a consumption of medical services

- even small homes are much less affordable than in 1955 because the price of land has drastically increased compared to 1955

- student debt is taken on because we know for a fact that college graduates statistically outearn people without college degrees, outliers aside, and the cost of schooling has ballooned for a variety of reasons, one of which is that the previous generation had voted to withdraw funding for schooling

One household member staying home is also supremely dangerous for that one household member at home, which wasn't a problem in 1955 raping your wife was legal and women couldn't even own fucking bank accounts so it wasn't like women had great options besides staying home! If staying home was so good how come women immediately got the fuck out of the house as soon as it was available to them?


I'm sorry but this is profoundly out of touch with the way a lot of people live. "We" is doing a huge amount of reaching in absolutely everything you're saying.

> We are wealthier today than at any point in human history.

Wealth disparity is also higher today than since records were started. You can't cite overall wealth without factoring that in.

My neighbourhood has a church which holds a weekly food bank, giving out a bag of food to anyone that needs one. The line goes far down the street every week. Do these people have "outrageous" lifestyles? Do you think they take luxurious vacations and sip frappuchinos? Not to mention:

> Homes are much larger now than in 1955.

Okay, how about... affordability? If you're going to claim housing is more affordable than it was in 1955 I'm going to need to see a citation.


>Homes are much larger now than in 1955.

Homes are not larger necessarily because of our "insane consumerist appetite." They are larger because:

1. Housing is an investment vehicle 2. Housing valuations are primarily driven by SQFT/SQM (when you rule out location) 3. The baseline costs of building (permits, utility connections, etc) are not driven by size and make up a huge % of the cost to build. 4. Zoning laws prohibit smaller builds and multi-family in many areas.


That's assuming you live alone or have no nearby friends/relatives who can watch your child. Most of the world somehow has kids without spending huge sums, because they have children when they are much younger and rely on nearby family to help, just as you will gladly help your children, etc.

This is how civilization propagates. The idea that only the wealthiest can afford to have kids by living in pure isolation and hiring teams of nannies and specialists is contradicted by the practice of opening one's eyes, looking around, and observing much poorer people having kids just fine.

But it requires making sacrifices. Those societies in which few are willing to make the sacrifices necessary die out, and healthier societies take their place.


> That's assuming you live alone or have no nearby friends/relatives who can watch your child.

Yes it is, because those friends and relatives also have to work in order to afford housing, healthcare, etc... grandparents that are happily retired, living off their savings and happy to donate their time is not close to a reality for many people.

> observing much poorer people having kids just fine

Define "just fine". I'm responding to the OP saying that having kids is "not expensive". It is. The fact that people make do, struggle and get by does not alter that fact, it just means they're doing it anyway. 1 in 6 children in the US lives in a food insecure home, that's not particularly "fine".

> Those societies in which few are willing to make the sacrifices necessary die out, and healthier societies take their place.

O...kay? I'm not sure a perspective that's this disconnected from personal lives is all that helpful. "Yes, raising a child in America in 2022 is difficult but don't worry, society will die and a new one will rise"... what's my reaction supposed to be there?


> Those societies in which few are willing to make the sacrifices necessary die out, and healthier societies take their place.

I think the comment means is that you can't have the cake and eat it too. Whether or not you want to make sacrifices in order to have kids, those choices will have consequences. Especially when sufficient number of people are doing it at the same time. The claim seems to be that the societies which prioritize sacrifices in order to raise children will outlives the ones that choose otherwise. Is that a good thing or a bad thing? Who knows.


> The fact that people make do, struggle and get by does not alter that fact

I rather think it does. If Jane Doe can make do for her 3 children at 21 year old on a $15k/year, what right do you ($100k+) have to say that children are expensive.


Did you stop reading before the “food insecure” part? That someone manages to successfully keep a child alive to adulthood does not mean that child has been well provided for.

But sure, if we wish to create a fictional story about a 21 year old raising 3 children on $15k a year I guess we can refute anything.


This is so sanctimonious and makes me angry.

Part of having kids is wanting your kids to have a life that's as good as, or better, than your current life. You want to give them all of the possible opportunities they can have in addition to instilling them with the values you deem important.

When I was in a position to potentially have a family, I realized that despite my good-on-paper job, my partner and I would not be able to afford any semblance of a good life if we stayed where we were living, and if we moved, I would never be able to see my family - all I would do is work and commute. I had to say no and it led to the dissolution of our relationship.

I don't have family around me, I don't have the option of having family around me, and it makes me angry that you say that I just need to "open my eyes" and see how the poor people do it.

Take a deep breath and reflect on what you said, please.


> makes it much more difficult

It’s unpleasant to live with 5 people on 20sqm, but if people can do it in Africa we can certainly do it in the US.


> Decades ago...

Even if we accept the (I think dubious) claim that we're worse off than people were in the 1950s (or whatever) there's thousands of years of procreation that precede that one specific comparison. Those people had it much worse than we do and they had many more children.


I never understand perspectives like these. The OP's statement was "having children is not expensive". How does "people had it worse a thousand years ago" relate to that? Surely by that logic we can't take issue with any facet of modern life?


No, you misunderstood. If somebody says, "I have only $10, I can't afford to do X" then the existence of millions of people who did X on $6 is directly relevant. It's not an abstract appeal to, "perk up, people used to have it worse!" It's a refutation of an explicit claim.


You don't think that's a simplistic analysis? For that to be true all external factors would have to remain constant and they obviously haven't.


Yes, it's very simplistic, but I think directionally correct.


>adjust your expectations

That's just another way to say they're inherently expensive. If they weren't, why are you adjusting your expectations?

I do think we exaggerate greatly how expensive kids are, for the most part the "exchange" is in time and not money. However, they are still a noticeable cost especially in countries with not great support systems.


> for the most part the "exchange" is in time and not money.

I agree. If you can have one person stay home kids are pretty cheap. My wife won't stay home, but if we could swap salaries I'd do it myself in a heartbeat.


Kids aren’t inherently expensive. The only thing they really need that you cannot provide without already being set up for it (a farmer) is food.

Everything else (sports, school, toys, etc.) is expectation.


We estimated that it costs 1.5 million to raise our kids just based on opportunity cost. If we factored in increased health insurance rates, and all the other expenses around having multiple children including needing to own a bigger car and house, factor out the tax credits in the US, it's more like 2.25 million. This is for a very moderate salary estimation for the non-working spouse.


I'm always confused about the bigger car thing, and I think it's marketing hard at work.

I'm getting myself, my wife, and my two kids to BMX practice (yes, with bikes) in a compact sedan.

What are people filling all that space with? Do you pack like you're crossing the Sahara every time you leave the house?

I came back and added this:

If houses were still built like they used to be, with walls and separation, it'd be easier to fit more people and stuff into fewer square feet, but even a roomy new home feels like there's always somebody with you.

I'd love to move into something small and inexpensive, but my 2 bedroom town home will have to do for the time being. Works just fine for us.


If you have more than 3 kids you need something bigger than a sedan. I was talking about seats, not legroom.


Or a second car and driver, which is inefficient at best.

Apparently I had forgotten that you can have more than two kids for a moment. I don’t know anybody who does, at this point, just read about them on the Internet.


Even in super socialized Sweden the first child costs around 180 000 USD (2021) [1] for the median example family. Second child is probably less expensive.

[1] https://seb.se/privat/livet/att-skaffa-barn/sa-paverkar-ett-...


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: