Slashdot Mirror


Programming in the Ruby Language

ShoeHorn writes: "Here is a good article (1st of a 4 part series), that introduces you to the Ruby language. If you are currently a programmer coming from the likes of C++, Perl, or Python, you will see some strong similarities (especially to Python)."

10 of 345 comments (clear)

  1. Mod Parent UP Funny, not DOWN Troll by ccoakley · · Score: 2, Interesting
    Come on people, this is (meant to be) funny, not a troll. It doesn't even remotely try to make a sound argument. A troll would say:

    For embedded systems: C# has a defined bytecode that can be JIT compiled onto a variety of special purpose chips without rewriting anything.

    Web Programming: C# has built in XML and network support, and don't forget that because everything tunnels over port 80, no firewall will prevent your code from executing!

    Instead, all of the statements are absolutely absurd. Maybe you don't think it is funny, but it is absolutely NOT a troll. Trolls try to say things that have a basis in reality but are completely non-constructive for the purposes of discussion to have people respond (I'm not sure where the line to Flamebait is, but...). This is just a joke.

    --
    Network Security: It always comes down to a big guy with a gun.
  2. Re:Lots o' languages by lavaforge · · Score: 2, Interesting

    Actually, as much as I hate to say it. Microsoft is on to something with the Windows scripting host. It can interperet Perl, VBScript, Jscript, and possibly some others (I don't remember offhand).

  3. Performance, gentlmen (and ladies)? by Quixote · · Score: 2, Interesting

    Most of the advantages being quoted are "ease of use", "rapid development", etc. Fine. But what about runtime? How does Ruby compare with Perl in running efficiency? Are there any benchmarks out there?

  4. Re:Lots o' languages by ChadN · · Score: 4, Interesting

    Actually, there is a lot of talk going on between L Wall and GvR to try to unify their bytecode interpreters (and maybe object models, etc.) for just this reason. I'm not awareof the details, but perhaps in some distant future, Python, PERL, and maybe even Ruby will all converge on a common backend (forget about TCL, though. It ain't never gonna happen)

    --
    "It's overkill, of course. But you can never have too much overkill." - Anonymous Slashdot Coward
  5. Horses for Courses by Hairy1 · · Score: 2, Interesting

    A associate once said about programming its "Horses for courses". What he meant was that we should use the best tool for the job at hand. When he said it he was talking about using Clipper (an dBase clone) over Quick Basic in 1990.

    Today I know two languages to what I consider 'professional level'. On Windows I develop stand alone applications with Delphi. Its easy to develop quality code - I define quality in this case by not crashing due to obscure memory errors. Its very hard to write code in Delphi which causes memory handling issues. Writing Delphi feels like the IDE wants to help you, but if you want to get your hands dirty you still can (unlike VB).

    For Web Development I now use Java. I wouldn't use Java for stand alone GUI apps because its still too slow compared to Delphi, but for server side web development it has the features I want - portability, easy to develop in, connects with SQL etc.

    Learning a new syntax takes time. You need to be sure that a new language is going to have a payoff in terms of being able to achieve something you can't in others. For years I wrote Delphi, as it was the best horse for the course. Now with Web Develoipment the course has changed, and Java is best (for me).

    That said, a programmer should be able to learn any language. But just because you can doesn't mean you should...

  6. word math by ToWnSaVeR2 · · Score: 1, Interesting

    $salut = $salut * 3 will result in the following: Oh, I am sorry. I didn't mean to warn you... Oh, I am sorry. I didn't mean to warn you... Oh, I am sorry. I didn't mean to warn you... I am sorry but i dont see the point in performing math operations on a strings. Oh, the line noise of Ruby...

  7. Didn't they call this Astroturfing a while back? by Anonymous Coward · · Score: 0, Interesting
    I can see little in Ruby to justify the people banging the drums in support of. It is an OK language. Not that different from Python and Perl. Aside from people throwing out oooh and ahhhh buzzwords that most people just parrot from their programming languages classes and do not really even understand, it just doesn't offer anything drastically different from what is already out there in the other scripting languages. You want to learn something totally different, try something different like functional languages or logic programming languages. Putting more tools in your kit and learning more languages is great. Just stop shoving them down our throats. Just make what are hopefully intelligent observations about the languages instead of "Use this one because the other ones suck... And you suck too if you use them. People bemoan BASIC because of the monstrosties that people used to code in BASIC. So what. You can code crap in any language. BASIC was developed for-- get this, its important-- NON-programmers.

    I do feel like there are people out there that are trying to promote Ruby over everything else just like the Gnome proponents act like they are getting a commission on every convert they get to switch to Gnome. Along with these, we have the people that say all Microsoft stuff is bad. Yeah, I don't like a lot of their software but show me a program (from any source) that can compete head to head with Excel and I will be impressed.

    Yes, that was a troll. That is what these promoters sound like as well but they are using the authorized troll buzzwords. Listen to all the opinions but take them with the grain of salt they deserve.

  8. Re:Strict languages vs. hacked languages by smallpaul · · Score: 5, Interesting
    I notice strong distinctions between those languages that have been developed by actual programming language researchers and those who hack together a language to scratch an itch.
    "Actual programming language researchers" are typically not even interested in designing languages for general purpose use. Often they are just trying to explore a particular idea of aspect of programming.
    Usually the latter turns out to be some baroque conglomeration of features piled on features, creating a very top heavy feeling to the language, while the former classification languages all have a purity to them, e.g. smalltalk, lisp, and c.
    I think you're going to have to define your terms if you want to make this point. How were Kernighan and Richie programming language researchers but not Van Rossum and Wall? By now, the latter two have spent about ten years of their lives thinking about almost nothing other than programming languages.
    Some would defend the "hack languages" as a means to Rapid Application Development, but Smalltalk has been shown to be the most productive language,
    Could you provide a reference to back up that claim? I'd like to see evidence that Smalltalk fares well at system administration or text processing.
    and Ruby/Python/Perl all seem to me to have a BASIC odor to them;
    Now you are really grasping. That claim isn't even solid enough to refute.
    ...I'm wondering if people are afraid to learn a new way of speaking?
    I don't know...are you? If you are into purity and elegance, I would suggest you give either Python or Ruby a real try. There are many Lisp fans that like both and Ruby is especially popular amoung Smalltalk users.
  9. Don't judge ruby based on the article by MeowMeow+Jones · · Score: 5, Interesting
    There's nothing wrong with it, it just doesn't get into any of the crazy stuff that makes ruby ruby. So wait until the other parts come out or check out the Pragmatic Programmers Guide.

    If Python was the result of Lisp and C++ having a baby, Ruby is the result of Perl and Smalltalk having a baby.

    --

    Trolls throughout history:
    Jonathan Swift

  10. Strict languages vs. hacked languages by Anonymous Coward · · Score: 4, Interesting

    I notice strong distinctions between those languages that have been developed by actual programming language researchers and those who hack together a language to scratch an itch.
    Usually the latter turns out to be some baroque conglomeration of features piled on features, creating a very top heavy feeling to the language, while the former classification languages all have a purity to them, e.g. smalltalk, lisp, and c.

    Some would defend the "hack languages" as a means to Rapid Application Development, but Smalltalk has been shown to be the most productive language, and Ruby/Python/Perl all seem to me to have a BASIC odor to them; I'm wondering if people are afraid to learn a new way of speaking?