On Tue, Jun 23, 2009 at 11:28 PM, Boyd Stephen Smith Jr.<b...@iguanasuicide.net> wrote: > In <20090623111601.gp19...@wasteland.homelinux.net>, Jochen Schulz wrote: >>明覺: >>> thanks, but before I got the benifit of so many languages, I have been >>> tired of learning them, maybe it cannot be called "learning", it's >>> just some parallel memory, for none of them bring new concepts to >>> C/C++. >> >>This is plain wrong. >>How do you do closures in C/C++? > > Function-objects. (Examples in STL.) > >>What about higher >>order functions, > > Function-objects plus tuple types. (Tuple types in latest C++ standard, I > think; In Boost anyway.) > >>pattern matching, > > That same way it's done it other languages, either statically (in C++ using > templates) or slowly and painfully. > >>dynamic typing? > > Bah. As long as the language is strongly typed, I prefer all my types to be > static. Type errors should be detected before run time. [I'm only willing > to let value errors slip until run time so I can accept user input. ;)] > > Still. C++ is neither strongly nor dynamically typed, which is quite > unfortunate, but are language choices. In comparision, it would be fairly > impossible to "do" weak, static typing in Ruby or Python, too. > > I don't agree with the OP, though. Languages like Perl, Python, PHP, and > Ruby allow you to trade off (very little) run time or memory for (usually a > lot) of man-hours. CPU cycles and RAM is much cheaper than Labor costs at > those ratios, and *all* of those languages have some way of calling into > C/C++ for things that just have to be written in those languages. > > I think the OP need to spend some time with Haskel, Erlang, Prolog, and > Lisp. <tease>Only *then* can you truly learn to *hate* non C-based > languages. ;)</tease> Thank you, my plan is to first learn C/C++, then learn other languages, I learn other languages in order to extract out their advantages into C/C++, not for using them, of cause, before I have the ability to modify the g++ compilers as I like. > -- > Boyd Stephen Smith Jr. ,= ,-_-. =. > b...@iguanasuicide.net ((_/)o o(\_)) > ICQ: 514984 YM/AIM: DaTwinkDaddy `-'(. .)`-' > http://iguanasuicide.net/ \_/ > >
-- Gnu.Linux.(Debian|gNewSense).Gnome.(Mozilla|Gmail|Evolution|Scim|Flashplayer|Codeblocks) Microsoft.Windows.(Vista|XP).(QQ|Game|Notepad++) Gcc.Gtkmm.Opengl 初禪言語寂滅,二禪覺觀寂滅,三禪喜心寂滅,四禪出入息寂滅....于貪欲心、嗔恚心、愚痴心不樂、解脫,是為無上禪。 -- To UNSUBSCRIBE, email to debian-user-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org