ruby is quite, er, slow.
|
http://www.thebuzzmedia.com/ruby-19-quick-speed-test/
Quote:
Quote:
|
Completely ignore my previous comment.
I updated my ruby to the 1.9 version and I can confirm that ruby is no longer slow. my personal test is to shuffle input lines, using fisher yates shuffle, (which I use to randomize mp3 file names to put on a stick). Code:
$ time ruby18 ./fisher_yates.rb 1.txt > 1 my previous comparison was with perl... Code:
$ time ./fisher_yates.pl 1.txt > 1 Code:
$ time ./fisher_yates.py < 1.txt > 1 Code:
$ cat 1.txt | wc -l | commify |
That's pretty impressive, from much slower than anything else to faster than Python!
|
Alright, my votes were:
C and Python. After reading and thinking, I'm going to make my final vote: C, C++, and Ruby or Python I don't know the details of why Python is better than Ruby, even though I've seen it said again and again, but I've read some Python tutorials and now I'm learning Ruby and in my opinion, I would vote Ruby. It's very nice, I don't see anything wrong with it. Python's a good language, also, but I prefer Ruby. |
interestingly (?) on my benchmark C++ may blitz the scripting languages
or may not be appreciably any faster! depending whether you use stdio or C++ streams: using <cstdio> Code:
$ time ./fisher_yates 1.txt > 1 Code:
$ time ./fisher_yates_iostream 1.txt > 1 |
I am so impressed I've just ordered "the ruby programming language"
|
ObjectPascal
I by myself do powerfull systems /applications in modern variants of ObjectPascal, its a pitty that this language is threated as second class citzen just becouse C/unix inventor, just did a unhappy commentin early 70'ies! Its a myth ObjectPascal is a feeble language only for educational porpuses. TIOBS list shows that interest on Pascal/ObjectPascal have been growing.
Not to mention others as Ada, Eiffel, SPARK. |
Quote:
|
marcelos!
java is of the future! the past more like. I think you may find that Tcl and Java interpreters are implemented largely in terms of C or C++, as is perl, ruby, python, etc etc etc I think you may find this is what is know as, reality :) |
It's really hard for me to choose between Ruby and Python, but Python is used for so many things that it makes it seem better to me. I'd like Ruby to be as popular as Python. If it got as popular as Python, I'd probably use it instead. I don't know which one I would say is better, but Python is used so much... Ruby seems to be very nice and neat and I don't see any problems with it, and Python is getting changed around too much in my opinion (unless they stop now, after 3). But Python is so popular and commonly used for pretty much anything, that it seems like the better one to start learning.
I don't like the amount of changes between Python 2 and 3, even though I'm sure it's a big improvement. I won't care if they stop doing that after 3 or 4, but if every major release has a hundred differences, it's going to turn ridiculous. Hopefully 4 doesn't have to go through too many changes and then it's done with. |
I wouldn't let popularity be such a big factor.
|
Quote:
Popularity means a larger coder base -> more resources in terms of libraries and snippets -> etc, etc. This is like speaking/writing in a common language... I bet there are more pieces of technical / Philosophical / history / <whatever> writing in English than in Urdu... IMHO, ... so you access a bigger pool of knowledge being an English speaker, than being an Urdu speaker... |
It depends
For Linux administration you should prioritize on Bash.
For a Solid understanding of the backbone of computing you should learn C which can be expanded to object C in the future. For more learing I recommend RISC assembly for Microcontrollers although this is a little out there for most PC users. A full assmebly language set looks like C as compared to RISC so I only think it is interesting if you only want it to use BIOS for system calls.If you are a genius I would also then learn Perl. I studied Pascal and loved it but it is harder to implement than C for embedded and other small stuff.Bite the bullet and learn C as a base Language or use Java because it is more popular for employment.:twocents: |
Quote:
I.e. Pascal was meant as an application programming (opposed to system programming) language. |
All times are GMT -5. The time now is 06:34 AM. |