News for hackers. Stuff that matters.
Re:Why Java? Tales from a Python Convert by cantastoria on Tuesday December 08, 2015 @06:13PM (#10700523)
Bingo! Coming from C# and C++, I had exactly the same realization using Python (before I switched back). I always ask Python programmers "but are you just keeping track of the types in your head?" because it's impossible to keep myself from doing that. If Python (and dynamic languages in general) are just pushing the type checking into the programmer's lap, I'm not sure what the advantage is other than less verbose (looking) code.
Re:Why Java? Tales from a Python Convert by gozur88 on Tuesday December 08, 2015 @06:59PM (#10700793)
That's the problem I had with perl. Sometimes one plus one is two, sometimes it's eleven, and the interpreter doesn't always do what you expect.
Re:Why Java? Tales from a Python Convert by kanatohodets on Wednesday December 09, 2015 @03:11AM (#10702523)
Perl has distinct operators for string concatenation and numeric addition (as well as string comparison/numeric comparison):

  $ perl -E 'say "plus: ", 1 + "1"'
  plus: 2
  $ perl -E 'say "concat: ", 1 . "1"'
  concat: 11
There is some type funkiness: a Perl variable can have both string and numeric components. However, which one is in use is only a problem in serializers (JSON, etc.) -- in normal usage you can rely on choosing the right operator for the type at hand.