HNHacker News
TopNewBestAskShowJobs

belmarca

235 karma · joined March 11, 2022

marc-andre (\dot) belanger (\at) umontreal (\dot) ca
submissionscomments
belmarca··on Ask HN: What's a good program for calisthenics for beginners that you have tried
But the vast, vast majority of people are _never_ going to develop "real" muscle mass in the meaning of the word used by weight lifters. It is much easier to get someone to do a few push-ups/crunches every other day than it is to get them to go to the gym consistently.

The benefits of simple calisthenics for muscle building aren't necessarily that great, but just doing them in the first place is already a big win. You will definitely get "fitter", but maybe not _that_ much stronger/bigger.

belmarca··on “My PGP key is compromised, and at least many of my bitcoins stolen”
This is the tweet: https://twitter.com/LukeDashjr/status/1609613748364509184
belmarca··on Ask HN: What's a good program for calisthenics for beginners that you have tried
For the _vast_ majority of people, the benefits are not necessarily in "building muscle" but just getting _some_ exercise.

I would say that push-ups and crunches beat any other exercise combination in terms of unit benefit per unit effort. Distractions and shyness can be practically eliminated as you can work-out from home, you can work-out while travelling as you don't need any equipment, risk of injury is relatively much much lower, warm-up is quick, rapid (sometimes _very_ rapid) progress is almost guaranteed, etc. Combined, this allows almost anyone to get the physiological and psychological benefits of working-out cheaply, safely and rapidly. There is just no substitute for the confidence boost that you can now easily do X amount of push-ups after just a few weeks of training. Best bang for your buck for most people IMO.

Of course, long-term it's probably a good idea to have a more diverse set of exercises =)

belmarca··on Ask HN: What's a good program for calisthenics for beginners that you have tried
It's incredible how fast you can progress with just these simple exercises. I suspect a lot of people would be quite surprised at how good they can get at push-ups and crunches if they commit to them for 3-4 weeks. Even starting at 5 each when waking up and before going to bed every other day, your body will get used to the effort very quickly. Make sure to properly warm up!
belmarca··on ChatGPT passes the 2022 AP Computer Science A free response section
It can simulate a Scheme interpreter with call/cc: https://old.reddit.com/r/ChatGPT/comments/zcu7ba/chatgpt_can... .
belmarca··on Ask HN: Have you ever heard of users demonstrating against software?
I have also worked in healthcare IT and while user input is obviously essential for building an efficient and useful solution, too much of it can be a kiss of death.
belmarca··on Pyffi – Use Python from Racket
Yes the core of the contribution is the threading mechanism. Writing a low-level integration of CPython and $SCHEME is not trivial, but any implementer can do it. The syntactic interface we have clearly separates Scheme and Python code and we don't have to have new semantics for e.g. method accessors (you just write them as you would in Python).
belmarca··on Pyffi – Use Python from Racket
Hey, just read your comment.

You seem to be using Scheme macros (try, async, list comprehensions, etc) to reproduce Python semantics in a Scheme syntax. That's one level on top of what we offer, i.e. I think it's very interesting, but as a library. Otherwise you're not writing Scheme anymore (your 'list' example looks good, but it's not Scheme).

We actually chose not to implement list comprehensions in the infix syntax because our grammar is a hybrid to allow us to have multiple target languages. You can already see how choices at this level can be mutually exclusive: the Python import syntax is not the same as the JavaScript import syntax.

Anyway, this is a vast space to explore, we just want to keep writing Scheme _with_ another language. Interesting, thank you.

belmarca··on Pyffi – Use Python from Racket
Pyffi automatically exports Python modules as scheme objects and that's quite practical. We worked on this briefly while building the Gambit interface to CPython (https://github.com/gambit/python), but ran into some quirks with the current Gambit macro and module systems that forced us to postpone. It is definitely something we want!

Our syntactic interface based on Gambit's infix parser (SIX) is quite ergonomic and allows you to write expressions that look just like Python, within Scheme code (and vice-versa). It's much more natural than directly[1] passing strings to 'eval', although you can certainly do so (the whole low-level API is available). Here's the 'cal' example:

  > \import calendar
  > (display (\calendar.month 2022 09))
     September 2022
  Mo Tu We Th Fr Sa Su
            1  2  3  4
   5  6  7  8  9 10 11
  12 13 14 15 16 17 18
  19 20 21 22 23 24 25
  26 27 28 29 30
[1]: SIX expressions are compiled to strings and eventually evaluated by CPython's eval.
belmarca··on Ask HN: 10k hours rule to master anything. Could I switch career when I am 43?
Switch to or from software engineering?
belmarca··on What Makes the Zig Programming Language Unique?
Ah but that's an implementation and design choice issue. It's like saying "classes are a bad idea because implementing them in pure C is cumbersome".
belmarca··on What Makes the Zig Programming Language Unique?
Which is precisely my point. As one other commenter said: "who have you been talking to?". Executing code at compile-time is a great idea in general, maybe those experts were talking about a very particular problem? It's not clear.
belmarca··on What Makes the Zig Programming Language Unique?
I don't think it's such a big issue but it is quite surprising to read, since these concepts have been known and used for many decades :)
belmarca··on What Makes the Zig Programming Language Unique?
You rely on a compiler to produce an executable, right? Well there are many "phases" that the code goes through before becoming machine code. "Compile time metaprogramming" is having control over one of those phases available from the language itself. Exactly how it is implemented is, well, implementation and language specific. But the fact that you can do it is quite useful. You can not only write programs, you can also write programs that transform or generate programs. The full extent of what you're allowed to do is implementation-dependent.

In Lisps, for example, that phase is called the macro-expansion phase (of which there can be layers of) and generally acts as a source-to-source transformation from s-exp to s-exp (possibly with side-effects). Here's an example in a Gambit Scheme REPL:

    > when
    *** ERROR IN (stdin)@8.1 -- Macro name can't be used as a variable: when
    > (when #t #f)          
    #f
    > (pp (lambda () (when #t #f))) 
    (lambda () (if #t #f))
So you can see the 'when' macro expands to an 'if', and that has to happen _before_ evaluation. So the REPL is in fact a REEPL (Read Expand Eval Print Loop).

Very useful.

belmarca··on What Makes the Zig Programming Language Unique?
Ah, so it's not macro-expansion but rather some "comptime" DSL?
belmarca··on What Makes the Zig Programming Language Unique?

    Programming language experts told Andrew Kelley, the creator of the Zig
    programming language, that having code which could run at compile time was a
    really dumb idea. But he went ahead and implemented it anyway. Years later,
    this has proven to be one of the killer features of Zig. In the Zig world, we
    call it comptime, from the keyword used to mark code required to run at compile
    time or variables to be known at compile time.
Which experts? The "comptime" is just macro-expansion from Scheme/Lisp which has been around for a long time. Aren't C++ templates also "code that runs at compile time"?
belmarca··on Structured concurrency and Lua
Does HN have a solid book recommendation on the topic of concurrency?
belmarca··on Ask HN: Have tech salaries been stagnant for the past decade?
Probably. But there is worldwide demand for good developers, try looking into remote work. I've spoken with many people who have more than one "job", which amount to long, but not insane work weeks.

One thing I think a lot of people underestimate is the sheer amount of _clueless_ (or almost clueless) software developers out there. There are a lot of young people with good intentions but very, very little "real" experience (writing a React web app for a class assignment isn't "real" except for saying you've tried the framework). Work experience is quite different from CompSci knowledge, evne if both are important! If you have even just 3-5 years of real experience building real systems with real failures and real successes, you should be quite easily employed elsewhere if your current job doesn't meet your expectations.

Keep this in mind: we don't let surgeons operate alone before they have 5-6-7 years of _post-doctoral_ education and training. If you have the battle scars and experience to get a project done properly, you should be fine.

belmarca··on Ask HN: Have tech salaries been stagnant for the past decade?
Is there any way you can work remotely? If you can get companies to pay you 250k, you can definitely write a nice resumé and probably get a remote job in this market.

I know people who have the kind of history you mention but didn't end up in tech and they don't make anywhere near 250k/y. So all is not lost ;)

belmarca··on Show HN: FFI Between Gambit Scheme and CPython
I mentioned this upcoming work in a comment last week. Here it is :) Any comments appreciated!
belmarca··on Show HN: Alumina Programming Language
We've been investigating coupling syntactic and low-level FFIs [1]. Our most recent work will be published at the upcoming Scheme Workshop [2], where we integrate Gambit Scheme with CPython. We share the concerns you have and have had quite good success with the Scheme<->Python interface! The syntactic interface makes it really enjoyable.

[1]: https://zenodo.org/record/4711425

[2]: The paper should be up in a few days I suppose.

belmarca··on The Excellent Schemer
Thanks. I'm interested in the interface cost, marshalling of data to and from .NET, if he had any tricks to pull to get it working!
belmarca··on The Excellent Schemer
Do you have any idea about performance? I'll just ask him in a few weeks but I'm really curious. I actually never used the .NET framework before.
belmarca··on The Excellent Schemer

    The current standard for Scheme is referred to as R6RS
R7RS small has been out since 2013. But yeah... "it's complicated".

We did an experiment a few months ago with compiling Gambit to JS and then serving it as an Office extension, using our JS FFI to interface with the Office JS library. Worked out of the box, but definitely some performance cost. Curious about performance on .NET.

BTW if Bob reads this, happy to hear you talk about this at the upcoming Scheme Workshop :) I guess this isn't available on Excel on the web?

https://icfp22.sigplan.org/home/scheme-2022 for those interested.

belmarca··on Ask HN: Who wants to be hired? (August 2022)

  Location: Montréal, Canada
  Remote: Yes, only
  Willing to relocate: No
  Technologies: Scheme, Lisp, JavaScript, Python, C, OpenBSD, Linux, macOS, PostgreSQL, SQLite, Vagrant, Packer, Ansible, Docker, Terraform, VueJS, Vanilla JS apps, Flask, front-end, back-end, DICOM, Solidity
  Résumé/CV: Chemist who worked in IT and software development, currently back in school to get a Masters in compilers.
  Email: See profile.
I have worked with a lot of technologies over the years, in various fields, shipped a few business apps (full-stack) still in use today. My primary goal is doing compilers research and publishing interesting papers. Currently focused on compilers and programming languages, with an interest in cross-language interoperability. Finding part-time work is a little bit harder than I thought! Send an email if you want to chat!

github.com/belmarca

belmarca··on Distilling the Real Cost of Production Garbage Collectors [pdf]
As sibling says. If it cannot be accessed starting from any of the GC roots, it is by definition unreachable and will be "cleaned up". What is meant by "cleaned up" varies with GC implementations.
belmarca··on Elegant six-page proof reveals the emergence of random structure
I am back in graduate school at 31 after a few years working and I also wondered if I was too old to go back. It is definitely possible if you have the drive to do it. I can say it is both easier and harder than my first time around. My drive to succeed is much higher, my focus is sharper, but my overall energy and free time budgets are more limited (kids). I would recommend if one can and wants to do it.
belmarca··on Ask HN: Where can we find the unsexy jobs?
Can you share some more about what you do? Looks interesting! Like sibling comment, I'm also looking for remote part-time work. Such opportunities seem relatively rare.
belmarca··on Would senior engineers be interested in working reduced hours or part time?
I wouldn't consider myself a "senior" engineer (what are the criteria?), but I'm going back to school after working for a few years. I am interested in finding a part-time job during my studies, but for the moment companies don't seem quite interested. I understand people in my situation are not a majority, but it would be great if more companies offered part-time work for already experienced programmers.
← PreviousPage 3 of 3