• NOW LIVE! Into the Woods--new character species, eerie monsters, and haunting villains to populate the woodlands of your D&D games.

Developing a cross platform program, what to use?

Code in whatever language you feel most comfortable with. Sure, "best tool for the job" sounds nice but if you are not familiar with the "tool" the result will be mediocre at best. Personally I prefer C++. You rarely have to bother with memory manangement thanks to the standard library. Have a look: www.sgi.com/tech/stl/table_of_contents.html For cross platform jobs Boost is invaluable: www.boost.org.

And don't listen to the people here who recommend you to _stay away_ from certain languages or design paradigms (such as "cross platform development is worthless"). Every single language has pros and cons. The person who dislikes a language and recommend against it obviously hasn't mastered the language yet. A programming language is just a tool. If you cannot use it properly it's your problem. I am interested in photography and It's amusing when people tell me "this camera cannot take good pictures". Makes me smile. :) (Then of course there are toy languages such as Malbolge and Brain:):):):), but I'm talking about real languages such as C/C++, Python, LISP, Java etc).

... And if you think all languages are pretty much the same when it comes to speed I recommend you to read about some compiler theory (I can wholeheartily recommend the Red Dragon Book). I also challange you to solve the problems at http://mathschallenge.net/index.php?section=project faster than my optimized C or Assembly code. ;)
 
Last edited:

log in or register to remove this ad

Hmm...

I'm thinking that Psionicist is talking about me, and that's unfortunate, because I'm really trying to help.

Some languages really are harder to use than others in most cases. Some languages aren't well-suited to certain tasks (to give an extreme example, SQL is great for manipulating relational databases, but terrible at anything else). The major break in productivity between widely-used languages today is between those without automatic memory management (C, C++) and those with (C#, Java, Visual Basic). That's reality. It's also true that well-optimized C++ code can be faster than well-optimized C# or Java code, but I'll almost always favor development time over performance, because a slow, finished program performs infinitely better than a fast program that's not done yet.

Cross-platform development really is hard to do well, so making sure you need to be cross-platform before attemting to be cross-platform is important if you're trying to minimize development time. Pretending that library A or toolkit B will magically make it easy just won't make it so.
 

drothgery said:
...and that's unfortunate, because I'm really trying to help.

Me too! We both know this topic is hotter than religion. :) I'm sorry if I came of as a complete jerk, not my intent.

drothgery said:
Some languages really are harder to use than others in most cases. Some languages aren't well-suited to certain tasks (to give an extreme example, SQL is great for manipulating relational databases, but terrible at anything else).

This is of course correct, but just because Perl is _the_ string processing language I, without any knowledge of Perl whatsoever, will not automatically write a better string processing program in Perl than in language I already master. You are of course correct that if Cergorach are willing to learn any language best for the job then he should by all means do it, but I got the impression that he already knew a couple of languages already and I think it's easier for him to start from there, instead of learning the best language for this particular job from scratch.

drothgery said:
The major break in productivity between widely-used languages today is between those without automatic memory management (C, C++) and those with (C#, Java, Visual Basic). That's reality.

Don't forget Python.

drothgery said:
It's also true that well-optimized C++ code can be faster than well-optimized C# or Java code, but I'll almost always favor development time over performance, because a slow, finished program performs infinitely better than a fast program that's not done yet.

I agree, but I think it's a bit unfair to compare a finished with an unfinished project. C++ is not that bad, worse than rapid development languages sure, but I don't think the difference is so big your project might fail because of it.

drothgery said:
Cross-platform development really is hard to do well, so making sure you need to be cross-platform before attemting to be cross-platform is important if you're trying to minimize development time. Pretending that library A or toolkit B will magically make it easy just won't make it so.

Depends. I am fairly comfortable with the Windows API and it wasn't until recently I discovered boost. It was not at all that difficult to port my windows code to boost code. Sure, boost is not the answer to all problems (I still use windows specific file IO functions for a few programs that deal with files larger than 2 GB) but for common tasks it works extremely well.
 

Into the Woods

Remove ads

Top