I've been learning .Net for work, which isn't too challenging. But after working with JavaScript for a year, having to use Pascal Case is the most annoying difference between the two languages.
Even after a few weeks working in C#, I still find it unintuitive to to write my methods and properties LikeThis
(Pascal Case) and not likeThis
(Camel Case). It's such a small change, but it still gets me.
What has been the most irritating differences for you when switching between languages or between stacks?
It's really the little things that make all the difference.
Top comments (21)
Whitespace being important. I'm looking at you, Python!
Does it mean you didn't indent your code before? 😱
I just think it was more deadly now 😂
Arrays in Lua start at 1 instead of 0. That’s the most annoying thing ever.
Learning JavaScript specifically, handling of
this
trivially tops the list. It wasn’t my first case of dealing with a language which uses a magic keyword for object self-reference, but the fact that it’s usable outside of object scopes and can have it’s value manipulated by the caller of the function combined with the at times strange scoping rules in JS made it a nightmare to learn to use correctly.Quoting styles are also a regular source of pain for me when switching languages. There are at least a dozen different ways to quote a string depending on which language you’re using, and some of them may or may not have differing meaning within the language or relative to other languages.
Ah yes the C# case style. That is still annoying and that's been my primary language at work for over 5 years.
I would say when using Typescript/Javascript is doing everything with async/wait. But that isn't exactly language specific.
So I'll go with needing to specify the file and import symbol is annoying. What are, programming in C. I'm used to specifying modules, but it isn't a specific file location.
"Python: white space is important." Its use of indentation for code block annoyed me.
If it doesn't want to use curly braces like in C family, it just can adopt begin...end statement from Pascal.
There is generics in current version of Go.
Array to String joining in Python. The syntax is as follows:
array = ["apple", "banana", "pear"]
separator = ","
separator.join(array)
Why is the action on the separator?! In most other languages, the separator is optional, but here its where you start!
I'm a Ruby guy and my impression of Python at the time was that it more functional.
I would have expected
join(array, separator)
or
array.join(separator)
but not
separator.join(array)
Yes, this is pretty annoying. It was designed like this because you can apply
str.join
to every iterable object, not only array. The same way aslen(iterable)
is not specific to array but generic and that's why it's not a method of the array likearray.len()
.12 different ways of saying "the" or "a" in German.
It was "programming language" tho, not actual, spoken languages 🤯
what about programming in German?
I am learning React and love it - but it is annoying when writing the JSX and writing class="abc" and forgetting it needs to be className="abc" (which is compiled to class="abc").... and having the compiler throw an error telling me to change it....
For me, it was probably two things.
Back when I learned Basic on the Apple II, there were commands called Peek and Poke. Our first home computer was a TI-99/4A, and their Basic had no equivalent commands.
The second is one that I think most people learning C struggle with, which is pointer syntax.
For me, go's bracket style was a deal breaker that means I don't want to learn it. I am fervently against
}else{
. Curly braces get their own line and I will never budge on that point!