Tags, Indentation, Curly brackets or Words | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Tags, Indentation, Curly brackets or Words

Vba uses words to define blocks (if then ... end if). C/C++/Java uses Curly brackets {} Python relies in Indentation Html/Xml are markup languages and uses tags What do you prefer if you could create your new program language? And why did you chose that?

2nd May 2017, 3:59 AM
Tiago Soares
Tiago Soares - avatar
3 Answers
+ 18
Never really thought of creating my own programming language... C++ is good as it is. :D That said, I'm going for curly braces if I had to choose.
2nd May 2017, 5:11 AM
Hatsy Rei
Hatsy Rei - avatar
+ 15
I prefer curly brackets style because it's neatness, clarity and easily understandable. If the statement in the "if" block is a single line you can decide not to use curly braces. Python indentation is another good option. But might be difficult to managed if you have too many nested conditions.
2nd May 2017, 4:21 AM
Wisdom Abioye
Wisdom Abioye - avatar
+ 3
{ I would definitely go for curly braces because when it comes to nesting, they are the only neat things and makes the code readable. }
2nd May 2017, 6:06 AM
Rishabh Agrawal
Rishabh Agrawal - avatar