# Compare between languages

**URL:** <https://www.ruby-forum.com/t/compare-between-languages/103977>\
**Category:** Ruby\
**Created:** [May 12, 2007, 6:56am UTC](https://www.ruby-forum.com/t/compare-between-languages/103977 "2007-05-12T06:56:00Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![anoosh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/65b543/32.png) [@anoosh](https://www.ruby-forum.com/u/anoosh)\
**Post date:** [May 12, 2007, 6:56am UTC](https://www.ruby-forum.com/t/compare-between-languages/103977/1 "2007-05-12T06:56:00Z")

</div>

what is the advantages and disadvantages of ruby vs. other programming  
languages such as java, php, python

---

<div class="post-metadata">

**Author:** ![anoosh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/65b543/32.png) [@anoosh](https://www.ruby-forum.com/u/anoosh)\
**Post date:** [May 12, 2007, 9:05am UTC](https://www.ruby-forum.com/t/compare-between-languages/103977/2 "2007-05-12T09:05:07Z")

</div>

> -----Original Message-----  
> From: anoosh [[mailto:removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)]  
> Sent: 12 May 2007 05:55  
> To: ruby-talk ML  
> Subject: compare between languages
> 
> what is the advantages and disadvantages of ruby vs. other  
> programming languages such as java, php, python

What are the advantages and disadvantages of apples vs. other fruits  
such as  
oranges, bananas, kiwi?

---

<div class="post-metadata">

**Author:** ![anoosh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/65b543/32.png) [@anoosh](https://www.ruby-forum.com/u/anoosh)\
**Post date:** [May 12, 2007, 9:25am UTC](https://www.ruby-forum.com/t/compare-between-languages/103977/3 "2007-05-12T09:25:53Z")

</div>

anoosh wrote:

> what is the advantages and disadvantages of ruby vs. other programming  
> languages such as java, php, python

see

> **[Comparison of programming languages](https://en.wikipedia.org/wiki/Comparison_of_programming_languages)**
>
> Programming languages are used for controlling the behavior of a machine (often a computer). Like natural languages, programming languages follow the rules for syntax and semantics.
> There are thousands of programming languages and new ones are created every year. Few languages ever become sufficiently popular that they are used by more than a few people, but professional programmers may use dozens of languages in a career.
> Most programming languages are not standardized by an international (o...

> **[Programming Language Comparison](http://www.jvoegele.com/software/langcomp.html)**
>
> Comparison of several popular 
> object-oriented programming languages

enjoy!

---

<div class="post-metadata">

**Author:** ![anoosh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/65b543/32.png) [@anoosh](https://www.ruby-forum.com/u/anoosh)\
**Post date:** [May 12, 2007, 6:26pm UTC](https://www.ruby-forum.com/t/compare-between-languages/103977/4 "2007-05-12T18:26:03Z")

</div>

On May 12, 11:54 am, anoosh [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> what is the advantages and disadvantages of ruby vs. other programming  
> languages such as java, php, python

[http://wiki.mozilla.org/Bugzilla:Languages](http://wiki.mozilla.org/Bugzilla:Languages)

---

<div class="post-metadata">

**Author:** ![anoosh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/65b543/32.png) [@anoosh](https://www.ruby-forum.com/u/anoosh)\
**Post date:** [May 12, 2007, 4:49pm UTC](https://www.ruby-forum.com/t/compare-between-languages/103977/5 "2007-05-12T16:49:44Z")

</div>

On 5/12/07, anoosh [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> what is the advantages and disadvantages of ruby vs. other programming  
> languages such as java, php, python

Programming languages are like shoes.

Do you want stylish, popular, or comfortable?

And if you want comfortable, sometimes you need time to break a new pair  
in.

And sometimes you keep wearing that old pair in the closet even though  
they’ve gotten out of style and really need to have the soles  
replaced.

Or you wear a popular/stylish shoe even though it kills your feet.

In other words this is a very personal question which only the  
individual can decide.

–  
Rick DeNatale

My blog on Ruby  
[http://talklikeaduck.denhaven2.com/](http://talklikeaduck.denhaven2.com/)

---

<div class="post-metadata">

**Author:** ![anoosh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/65b543/32.png) [@anoosh](https://www.ruby-forum.com/u/anoosh)\
**Post date:** [May 13, 2007, 3:16pm UTC](https://www.ruby-forum.com/t/compare-between-languages/103977/6 "2007-05-13T15:16:36Z")

</div>

xymip wrote:

> [stefan’s-computer-2:~] stivi% puts 1+2  
> tcsh: puts: Command not found.
> 
> Has the command changed?

tcsh doesn’t have a puts command and never had. Ruby has a puts command,  
but  
you didn’t actually start ruby, you entered the command into your shell.  
You have to start the ruby interpreter or irb before you can enter ruby  
code.

---

<div class="post-metadata">

**Author:** ![anoosh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/65b543/32.png) [@anoosh](https://www.ruby-forum.com/u/anoosh)\
**Post date:** [May 13, 2007, 2:56pm UTC](https://www.ruby-forum.com/t/compare-between-languages/103977/7 "2007-05-13T14:56:34Z")

</div>

HI,  
Using terminal with ruby I encountered a problem  
with the puts command. Here is the track:

Last login: Sun May 13 05:42:08 on console  
Welcome to Darwin!  
[stefan’s-computer-2:~] stivi% echo hello world  
hello world  
[stefan’s-computer-2:~] stivi% ruby -v  
ruby 1.8.2 (2004-12-25) [universal-darwin8.0]  
[stefan’s-computer-2:~] stivi% puts 1+2  
tcsh: puts: Command not found.

Has the command changed?

Thanks in advance  
Stefan

---

<div class="post-metadata">

**Author:** ![anoosh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/65b543/32.png) [@anoosh](https://www.ruby-forum.com/u/anoosh)\
**Post date:** [May 14, 2007, 5:05am UTC](https://www.ruby-forum.com/t/compare-between-languages/103977/8 "2007-05-14T05:05:56Z")

</div>

On May 13, 9:15 am, Sebastian H. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> > ruby 1.8.2(2004-12-25) [universal-darwin8.0]  
> > NP: Milhaven - Clean Room  
> > Ist so, weil ist so  
> > Bleibt so, weil war so

Yes.  
Thanks both.  
Starting irb the commands work.  
I am using Chris P.'s 2005 book to learn ruby on mac.  
The newer ruby books are still out (lots of demand in our library).  
They are on reserve and I should get them in a few weeks.  
In the meantime what is the best way to create a program file and then  
run it via terminal?  
Thanks for the help.

---

<div class="post-metadata">

**Author:** ![anoosh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/65b543/32.png) [@anoosh](https://www.ruby-forum.com/u/anoosh)\
**Post date:** [May 14, 2007, 5:19am UTC](https://www.ruby-forum.com/t/compare-between-languages/103977/9 "2007-05-14T05:19:57Z")

</div>

On 5/14/07, xymip [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:

> In the meantime what is the best way to create a program file and then  
> run it via terminal?

Edit the file with your favourite text editor, save it with a .rb  
extension, then run it from the prompt using ruby .  
The command line arguments are captured in ARGV. For example

~ $ cat \>\> greet.rb  
name = ARGV[0]  
puts “Hello #{name}”  
~ $ ruby greet.rb Martin  
Hello Martin  
~ $

martin

---

<div class="post-metadata">

**Author:** ![anoosh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/65b543/32.png) [@anoosh](https://www.ruby-forum.com/u/anoosh)\
**Post date:** [May 14, 2007, 7:55am UTC](https://www.ruby-forum.com/t/compare-between-languages/103977/10 "2007-05-14T07:55:06Z")

</div>

Martin DeMello wrote:

> On 5/14/07, xymip [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid) wrote:
> 
> > In the meantime what is the best way to create a program file and then  
> > run it via terminal?
> 
> Edit the file with your favourite text editor, save it with a .rb  
> extension, then run it from the prompt using ruby .

Well, if it’s a program that you are going to run a lot, I’d suggest  
a) saving it without the .rb extension, making it executable via “chmod  
+x  
” and moving it into a directory in your $PATH or  
b) saving it with the .rb extension, making it executalbe and create a  
symlink  
in your $PATH that doesn’t have the extension.  
Then you can call it via “ ” from anywhere you want.  
The latter is what I do.

---

<div class="post-metadata">

**Author:** ![anoosh](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/a/65b543/32.png) [@anoosh](https://www.ruby-forum.com/u/anoosh)\
**Post date:** [May 13, 2007, 3:35pm UTC](https://www.ruby-forum.com/t/compare-between-languages/103977/11 "2007-05-13T15:35:41Z")

</div>

On Sun, 13 May 2007 05:52:56 -0700, xymip wrote:

> [stefan’s-computer-2:~] stivi% puts 1+2  
> tcsh: puts: Command not found.
> 
> Has the command changed?
> 
> Thanks in advance  
> Stefan

Hi Stefan,  
you should give irb a chance:

philip@jupiter:~$ irb  
irb(main):001:0\> puts “hello world”  
hello world  
=\> nil  
irb(main):002:0\>
