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

355 / 113

( = 3.1415929204 )

is one approximation I have read about, attributed by some, to ancient or medieval Indian or Chinese mathematicians.

https://en.wikipedia.org/wiki/Approximations_of_pi


How does it do the proving?

Spawns and calls z3 under the hood, I did let it cheat there because otherwise it's rabbit holes below rabbit holes all the way down :)

thanks.

Can Raku do something like this? I was lightly exploring it recently, and I thought I saw that something like this may be possible with it.

I'm not super familiar with Raku, but if RakuAST is what you had in mind it looks a bit different:

    use experimental :rakuast;
    
    my $ast = RakuAST::Call::Name.new(
      name => RakuAST::Name.from-identifier("say"),
      args => RakuAST::ArgList.new(
        RakuAST::StrLiteral.new("Hello world")
      )
    );
Looks more like "low-level programming an AST" (which I believe other languages offer as well), rather than using a bidirectional transform. I don't know how you'd get Raku code back out, for example.

Edit: I should have looked deeper, `DEPARSE` does exactly this:

https://docs.raku.org/type/RakuAST

Neat!


It also goes from source code to AST:

  $ raku -e 'say Q|say "Hello World!"|.AST'
  RakuAST::StatementList.new(
    RakuAST::Statement::Expression.new(
      expression => RakuAST::Call::Name::WithoutParentheses.new(
        name => RakuAST::Name.from-identifier("say"),
        args => RakuAST::ArgList.new(
          RakuAST::QuotedString.new(
            segments   => (
              RakuAST::StrLiteral.new("Hello World!"),
            )
          )
        )
      )
    )
  )

thanks, all.


Let's have more programming language posts (even about "retro" ones like Icon, SNOBOL, Bliss, MUMPS, etc.), guys.

And less about AI topics.

Om.

https://emojipedia.org/om

https://en.wikipedia.org/wiki/Om


And therein lies the tragedy of folks exploiting well known culturally loaded symbols/concepts for attention/etc. on the Internet.

For example, I really don't know what to make of this similarly named language; enthusiastic kid or attention-seeking influencer? - https://omlang.com/


people exploit anything for attention/etc. on the Internet.

if everyone on HN started downvoting all the AI posts (atleast the slop ones) it would cut down submissions by half

I think it's going to take some time for the reality of ns;nt and the disappointments to sink in. They need to learn that one cannot "claw" their way to a money machine.

Can you name (in Tamil, but written in English) and describe the dishes in which those lotus parts are used? Interested.

1. Thamarai Thandu Poriyal / Varuval (Stir-fried Lotus Stem): A popular dish where the lotus stem is peeled, sliced into coins, and stir-fried with coconut oil, mustard seeds, shallots, green chilies, curry leaves, and sometimes sambar powder or chili flakes.

2. Thamarai Thandu Uppukari (Lotus Stem Dry Curry): A preparation where the lotus stem is boiled with salt, then deep-fried or stir-fried until light golden brown to create a crispy side dish, often served with rasam rice.

3. Thamarai Kizhangu Vathal (Dried Lotus Root Crisps): A traditional, shelf-stable snack where the lotus stem is sliced, salted, and dried, then fried before consumption.

4. Lotus Petal Paruppu Usili (Steamed Lentil Crumble): A dish made by finely chopping tender inner lotus petals and mixing them with coarsely ground, steamed, and crumbled lentils (dal), similar to traditional Tamil Paruppu Usili.

5. Thamara Vadai (Lotus Stem Fritters): A traditional snack in South India that uses sliced lotus stem in a seasoned batter, similar to a vadai.


saw the reply a bit late, but thanks.

>Tcl/Tk to this day is the best tool to make GUI frontends for CLI applications.

Why? Please elaborate. I've heard others say this, but would like to know more.

>Besides that, in the past I used it in production for intranet database entry applications.

GUI apps?


> Why?

CLI applications typically read text from stdin and write text to stdout. The tcl model of "everything is a string" makes exactly the right abstraction to create GUI frontends for CLI applications rapidly and keep them simple at the same time.


thanks.

> Why? Please elaborate.

Tk's GUI object model is sitting at a reasonable maxima between trivial to make use of vs. triggering the events necessary to make the GUI active.

Small example. You want a button on your GUI that triggers a procedure called "process" when it is clicked, this is the code you need (if you are fine with the remaining defaults) (and assuming you used 'pack' as the geometry manager):

    button .process -text "Process Entries" -command process
    pack .process -side top

And a fully active GUI button will now appear at the bottom of your Tk window, with a label of "Process Entries" and when you click it, a Tcl procedure named "process" will be executed.

thanks.

Why did you think of changing the ip address?

Rate limiting IP addresses is one of the many tools in YouTube's anti 3rd party client toolbox.

what's the latest news about OpenD, anyone?

I had read about the split (D vs. OpenD) recently on the Dlang newsgroup.

Also, just had the thought that the split may damage Dlang's progress / prospects, for users, like the Phobos issue etc. stuff was supposed to have done.

I don't know much about those details either, I had just read a bit about it earlier, as an interested light user of the language.


>Oh a programming language certainly needs to have traction and community for it to succeed, or be a viable option for serious projects.

You are totally right, sir.

>You can code your quines in whatever you'd like, but a serious project needs existence of good tooling, good libraries, proven track record & devs that speak the language.

Now, you HN user who calls yourself 4gotunameagain (which type of name is already a red flag for those in the know, because usually used by trolls), do us a favour by posting the link to at least one of your so-called serious projects here. Put your money where your mouth is.


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

Search: