💾 Archived View for dioskouroi.xyz › thread › 29416422 captured on 2021-12-04 at 18:04:22. Gemini links have been rewritten to link to archived content

View Raw

More Information

⬅️ Previous capture (2021-12-03)

-=-=-=-=-=-=-

Show HN: I built an online programming language

Author: sandes

Score: 67

Comments: 24

Date: 2021-12-02 14:22:35

Web Link

________________________________________________________________________________

fjfaase wrote at 2021-12-02 15:56:46:

I build a meta online programming language, where you can define your own grammar ;-). See:

https://fransfaase.github.io/ParserWorkshop/Online_inter_par...

An example grammar is found at the bottom of the page.

sandes wrote at 2021-12-02 14:23:09:

It's a multi-language pseudocode interpreter so you can write and run code in English, Spanish, Portuguese and French in your browser.

rabarbers wrote at 2021-12-02 15:35:23:

Link to documentation is broken:

https://codigo.so/docs/

(also link to community is broken, but I care more about Documentation link).

sandes wrote at 2021-12-02 15:37:10:

Yes, I'm building it, you can see some examples at

https://codigo.so/editor.en/

[Ctrl + Enter] list all built in functions

fruit2299 wrote at 2021-12-02 16:17:52:

awesome!

SwiftyBug wrote at 2021-12-02 16:19:56:

Very cool!

As a native speaker of Portuguese, I think it would look nicer the verbs were all in the same conjugation, simple present. You have "retornar" (return) which is in infinitive form and "escreva" write which is in the present imperative mode. I would choose to put all the verbs in the simple present:

retorna => return

faz => do

escreve => print

I couldn't find the Portuguese version for "break", but in my opinion it should be "quebra" or "interrompe".

If this project becomes open source, I'll be happy to contribute.

Vox_Leone wrote at 2021-12-02 17:18:42:

Great project. Congratulations.

I am also a pt_BR speaker. To be completely frank, I would say I'm more comfortable programming in English. In the “test” example, for instance, I wouldn't know which alias to use, whether 'verdadeiro' or 'verdade'. But it's pretty cool in English. Kudos

SwiftyBug wrote at 2021-12-02 22:32:03:

I'd only choose "verdade" if its opposite is "mentira". Otherwise, I'd go with "verdadeiro", which goes better with "falso".

sandes wrote at 2021-12-02 17:52:36:

Thank you!

Can you help me set the correct alias for each word in portuguese?

rlf_dev wrote at 2021-12-02 17:19:56:

I also think having everything in the formal form makes it a little bit jarring, like the sample code in the main page having the keyword "faca" when "faz" would be much more clearer.

sandes wrote at 2021-12-02 16:33:23:

Thank you! I really appreciate this :)

rmnclmnt wrote at 2021-12-02 16:18:14:

The french pseudo-code reminded me of my freshman year in Computer Science degree, so much nostalgia! Completely forgot about all that since then, but I wonder if using your mother tongue to learn programming is truly effective, especially in non-English speaking countries?

dgellow wrote at 2021-12-02 17:38:06:

Translating programming languages and computer science concepts is IMHO a terrible idea. That creates fragmentation, which makes it very difficult to get access to the broader programming community and provides very little benefits for students understanding. Based on my personal experience, in the French speaking world almost everything is translated, which makes it hard to find online references and creates a lot of friction when you start to be confronted to the English terminology. As an example, "a thread" is a term I can easily search online and that everybody is using, where "un fil d'exécution" is used by absolutely nobody. You basically have to learn everything twice.

Regarding programming languages, one of the first job I had was with WinDev, using the French dialect. It was a horror to deal with it, and makes it especially hard to switch to something else if you get too comfortable with it. Something that people pushing for translation miss is that a programming language isn't an actual language where you have words that you compose. It is a set of operators/keywords to express a logic or to produce an effect. The actual operators/keywords do not matter that much when you're learning: "for", "var", "while", "if" are just keywords that you map in your mind to the actual effect they produce. They could technically be replaced by shapes or emoji without creating too much learning issues (terrible idea, please do not do this). By learning the same English keywords that everybody is using you can at least easily switch between technologies and get access to the wider international community.

sandes wrote at 2021-12-02 16:39:04:

:) Glad to hear this!

In teaching, simplification is really important.

Take a look at this [1] simple script in Portuguese and tell me if it seems intuitive to you.

This is the situation of most of the people trying to learn to code here in Argentina/Latam using very large and professional programming languages. I hope this can help them.

[1]

https://codigo.so/editor.pt/fb3e08c2-e929-4379-81fa-c3126bbd...

rmnclmnt wrote at 2021-12-02 17:23:11:

Sorry, I do not speak Portuguese! However, I could easily find-out what the snippet was doing by simple logic.

I have been teaching programming/data for the past 2 years and you're right, simplification is of utmost importance for students. Actually, when teaching programming with Python, I go with them in the process of translating their logic to English first then it's almost a 1-to-1 mapping with the instruction set (for simple algorithms). Same goes for SQL.

Anyhow, nice concept here, curious to see where it goes!

sandes wrote at 2021-12-02 18:19:33:

Thank you for your feedback.

I think codigo.so can be good for non-English speaking students trying to learn to code.

For the HN audience it doesn't add much value.

clintonc wrote at 2021-12-02 17:23:52:

"Docs" is broken :) How can I learn about the language, aside from the examples?

This scratches a peculiar itch that I have which isn't _quite_ addressed by other solutions (codepen, stackblitz, replit, etc). Can you import libraries at all?

sandes wrote at 2021-12-02 17:38:18:

> "Docs" is broken

Yes, I'm building it, you can see some examples at

https://codigo.so/editor.en/

[Ctrl + Enter] list all built in functions

> by other solutions (codepen, stackblitz, replit, etc)

No, codigo.so is a pseudocode interpreter specially designed for people who don't speak English.

alexvoda wrote at 2021-12-02 16:02:59:

Will you open source this? If yes, i would like to contribute another language.

Also, since this is supposed to be pseudocode, maybe it would be better to replace the atribution operator with something else, and the comparison operators with their math variants.

Raudius wrote at 2021-12-02 16:32:43:

I built a similar (albeit less polished) javascript interpreted language as a lockdown project.

https://github.com/raudius/homegrown

ksec wrote at 2021-12-02 16:41:51:

Off Topic, at the bottom of the page;

Backed by AWS startup programs

What does that mean ?

midwestemo wrote at 2021-12-02 16:46:13:

I think it's meaning this

https://aws.amazon.com/startups/

ksec wrote at 2021-12-02 16:48:01:

I was thinking something similar, because for a moment I thought AWS are starting to fund startups.

sandes wrote at 2021-12-03 00:03:57:

No big deal, I applied with my company Cardallot Inc. and they gave me $ 20k in credits