

Ask HN: How do you manage working with multiple languages? - alt

Everyone has a language that they love working in, but sometimes the problems at hand require different tools. This may mean writing code in 2 or 3 languages a day. How do you write great code in any language while staying true to the language's ideals and not trying to transform it to work as other languages?<p>EDIT:  When working with C/Cuda, python, and perl throughout the day, I find myself being pythonic in perl, and whatnot, or not being pythonic in python after working in C/cuda.  Then I have to go back in refactor.  I'm sure I'll get used to it eventually, I was just wondering what HN does to keep their head straight.
======
kevinelliott
I personally try to segment my time so that I'm focused in one language at a
time. This gives me an opportunity to search the web and read documentation on
the language at the same time, so I'm improving my ability to use the
language.

For example, I often work with Objective-C (iPhone/iPad) as well as Ruby +
Ruby on Rails + HTML + CSS (backend). Some days I really need to work in both
environments, but I try to spend most of my days focusing on one.

------
kertap
I have to jump between JavaScript and Java at work. The biggest problem for me
usually is the small syntax mistakes I create, e.g. using var in a java file
or "int i" in a javascript for loop.

But I find the differences in syntax help compartmentalize how I code. As soon
as I get the compiler error in the java file it jar's be back into the java
way of thinking.

------
ashleyreddy
I work on C# on the pc side and objective C on the iPhone side. I don't have a
problem going back and forth. Try it out for yourself. I don't think its that
much of an issue.

