Y
Hacker News
new
|
ask
|
show
|
jobs
by
finger
837 days ago
if __name__ == "__main__" { print_message(10); }
This just looks wrong without parenthesis around the conditional statement.
6 comments
ufo
837 days ago
The purpose of parenthesis is too let the language know when the condition ends, and the statement begins. In a language with mandatory curly braces, the brace does that job already.
link
paulcole
837 days ago
I’ve got a side project called Parenthon that I’m going to release soon. Let me know if you want in on the beta!
link
kova12
837 days ago
It does, doesn't it? I wish there was some sort of compat layer which would allow to natively use python libraries in Javascript
link
dartos
837 days ago
https://github.com/extremeheat/JSPyBridge
Happy hacking!
link
ComputerGuru
837 days ago
Welcome to rust!
link
apetrovic
837 days ago
Huh? Rust, Go, Swift and probably many more languages does the same.
link
dvh
837 days ago
In pascal you can call function that has no arguments without parentheses: writeln;
if x = 5 then writeln;
link