I just found it on a reddit post from r/programmerhumour and I found it to be actually decent after I mentioned someone nim in here on HN and they said that they don't like whitespace and I thought that they were fair and I actually looked at a nim processor that could do something like it but there were none.
Although, This isn't related to python, I actually went into Nim forum to see that they were using it because of their inspiration with python and so It was a bit funny / semi full circle seeing Python with braces.
Maybe we need to make Nim with braces as well :> I think that some people might genuinely like that. Its definitely a bit in my mind.
Nim actually already supports using `()` as braces most of the time for most constructs. So, in this sense it is more like Haskell than Python, though the latter is more well known.
Nim is also more "expressional" than Python in many ways. So, for example, in Nim you can say:
let x = (try: dict[key] except: 2)
for i in 1..x: (
echo i
)
Most users hate how that looks, though, much as most users of bracist languages also hate:
int foo(char bar) {
int c = 0;
for (char i = 0; i < bar; i++) c++;
return c; } // could be many '}' here
In reality, these discussions feel more like style guide wars, reformatted as PLang syntax wars, pun intended.
Wow tbh, I didn't know that you could do something like () in nim, I mean if somebody reallyreally wants to use something similar to paranthesis, they sort of (could?) actually.
Like, as to that person who thought Nim to be a deal breaker because of whitespace, I think that this new information might help them to atleast try Nim!
Thanks, I learnt something new today thanks to ya!
I actually noticed that other comment you mentioned and almost said something at that time. The style is just not mentioned much and Python is about 1000x more well known than other offside-rule PLangs like Haskell. There are also enough exceptions, in Nim at least, that a true bracy fan would have at least some disappointments here & there.
In general Nim's syntax affords much, much more choice than Python, from UFCS to user-defined operators to macros to term re-writing macros to etc., etc. It's really a step up from Python in so many ways with a lot of compile-time checking and safety and essentially the same perf as C++. It's a shame it's not a little more popular.
Well I actually really really appreicate nim and consider it to be a lovely language of sorts and want to build more in it just for hacking purposes/why not.
I mean. sure they might be a bit disappointed but I didn't even know that () this syntax works, I mean {} is already used by something like set iiirc so something like it for nim might break existing functionality.
I just really thought about how to convince others who might have the same grievances with nim because personally I don't mind whitespace but I also want nim to succeed of sorts.
Nim to me is a love letter of sorts to programming in general. Maybe I romanticize nim but the only language I feel this sense of writing software in is maybe golang.
I am forced to write typescript/python tho, yes I know that nim can be transpiled to js but still, I want to learn Nim too and just build some side casual projects like how people are building with zig. I don't want to suffer with memory management right now so I would use their garbage collection and then if someone wants performance, they can modify my software rather easily for that purpose too.
I was thinking of creating a music player from scratch in nim just for learning it. idk, i really want to build something in nim / maybe even contribute to its small libraries to increase the library support
This is interesting. I don't hate Python, but it has a few things that I find irritating enough that I tend not to use it. Topping that list is that white space is significant.
https://www.reddit.com/r/ProgrammerHumor/comments/1np5g2t/th...
Here is the reddit post
Here is the HN person's comment https://news.ycombinator.com/item?id=45346840
Although, This isn't related to python, I actually went into Nim forum to see that they were using it because of their inspiration with python and so It was a bit funny / semi full circle seeing Python with braces.
Maybe we need to make Nim with braces as well :> I think that some people might genuinely like that. Its definitely a bit in my mind.