There’s long been a push to stop writing code as a sequence of lines and go to something graphical, which has been very successful in some areas and less so in others. But even when you use something graphical like Scratch, it is really standing in for lines of code? Many graphical environments are really just interface builders, and you still write traditional code underneath. [Masato Hagiwara] asks the question: Can you write code that is actually a 2D graphic? Where the graphical layout isn’t a cover for code, but is the code itself? His answer is Recto.
Whereas a C program, for example, has a syntactical structure of lines, a Recto program has rectangles. Rectangles can contain data, and their structure naturally mimics the kinds of structures we usually use: columns, rows, matrices, and so on. Rectangles can also contain… wait for it… other rectangles. Special rectangles act as dictionaries or sets.
We thought this sort of reminded us of Lisp, and, in fact, [Hagiwara] makes that clear later in the post. The real problem is how do you…write? draw?… this kind of code? At first, he laid it out in a spreadsheet before compilation. Now he’s built an editor for it, and you can try it in your browser. There’s also a limited-feature compiler that can handle simple programs.
[Hagiwara] goes on to show how this representation would work for natural human languages, too. Honestly, we have enough trouble with English and the few other human languages we struggle with, but it is interesting to contemplate.
If you like strange languages, there’s Piet. Not that either of these is the weirdest we’ve ever seen.
You want reasonable graphic programming? Try DRAKON.
This looks more like snusp than lisp.
We do write graphical code where it makes sense: simulink, scicos, “ladders” in plc.
Few years back I was supposed to “write software” for PLC to control pneumatic hammers. Code was simple – each hammer was controlled by one DO – all in all 32 hammers. One by one to be triggered every X seconds (where X is either 10 or 20 sec.).
Anyway – Codesys (i think it was it) allowed to choose which language I want to use. I chose pascal style code to make it short and easy to write. But my boss wanted to use some “diagram style graphs” (not even ladder). It took me much more time and it was much less readable.
Recto looks like someone was trying to make whitespace even more important than in Python, but didn’t want to go all the way to the actual Whitespace programming language.
I was going to ask if Python was considered a “graphical” programming language…
And the name… Maybe this Japanese guy thought about “Lecto”. Recto reminds me something on the back…
Programming — writing program code, that is — is really simple. What’s not so straightforward is articulating the problem and stating it in a form that’s logical and obvious. No amount of ‘language du jour’ will fix this basic fact of life.
This is a very important point that ought to be obvious but is not appreciated as much as it should be.
I see it particularly in new programmers who are fresh out of their studies and have never written real production code, just toy projects and academic stuff. They can pick up the language syntax and concepts very quickly, but working out how to structure their thoughts about what the code has to do and express that in the language is much harder, and takes time to learn.
You mean like pulling the hardware data sheets, figuring out what registers do what, what bits need to set/cleared in what order, what hex masks to use. And then write the interrupt handler to do the right thing? Simple … Right? ;) or using the PIO and DMA in a Pico… Yeah, a = b + c is simple … IF that is the ‘correct’ formula for what you are trying to do ;) . Oh, and then using the correct (or good enough) data structure for the problem ( array, linked lists, red-black trees, hashing, randomization, sort method, etc.) So simple? Depends on one’s point of view and what the problem is…
Going to drop this here: LabVIEW
The horror…
Forgive me master control for I have programmed in Labview. I think I went down into the ninth level of hell with subroutines.
+1, Have done quite a bit of Labview work. It gets very little respect among programmers, but if you look at it, all the pieces of a text based language are there. The GUI integration is what makes it useful to me.
Why stop at 2D code? We can go further and make a language out of 3D, or even 4D or (n)D code. The IDE just needs to be a bit more elaborate, and our craniums will need to be bigger :)
Well, the name checks out. Sounds like something some CompSci theorist extracted from a similarly-named orifice.
Didn’t someone already create a two-dimensional programming language, in Befunge?
https://en.wikipedia.org/wiki/Befunge
But, is it separated by spaces or tabs?
Anyone who thinks programming is hard, hasn’t been around long enough…
It’s hard if you’re using something like C++ or Qt. Coding in C# is pretty easy ever for total beginners. Just see any tutorial on youtube if you need help.
My goal is the opposite : creating the most
powerful , succinct , personal programming language & environment possible .
chip Forth whitespace delimited RPN where any line in your notes , including defining new words , can be evaluated simply by tapping F6 instead of ` Enter .https://CoSy.com is a timestamped notekeeping environment built & commanded in array language evolved from APL , via K , in open to the
I’ll admit , I can’t figure out what the hell that jumble above does — which I guess is its point .
I will comment that Ken Iverson considered one of his significant accomplishments linearizing math notation into an executable string .