1.9.1?

Hi there,

I'm about 2 weeks into my learning attempt at Ruby (1.8.6 is what I've
cut my teeth on).

Can someone give me a rational assessment of the differences between
the two language versions, and which one I should continue to pursue?

I'm mainly using Ruby with Rails to make basic webapps for my own
edification.

Thanks!

Alex

Very short answer:
- new virtual machine (previously just AST interpreter)
- memory diet for some objects (Object, Array, String etc)
- improved speed (see
http://antoniocangiano.com/2008/12/09/the-great-ruby-shootout-december-2008/\)
- added character encoding support (previously works only with raw bytes)
- new syntax for hashes with symbols as keys, hashes preserve keys order
- many changes to API (improved, added consistency, removed deprecated code etc)
- changes in language semantics (for example block arguments now works
(almost?) the same as method arguments)
- new lambda literal: ->
- external iterators (class Enumerator) now are built in
- new concept such a fiber (class Fiber)
- native threads (but with GIL like python)
- rubygems, rake are built in
- minitest supercedes old test/unit

···

On Tue, Feb 3, 2009 at 6:14 PM, yuckysocks <alex.m.mcpherson@gmail.com> wrote:

Hi there,

I'm about 2 weeks into my learning attempt at Ruby (1.8.6 is what I've
cut my teeth on).

Can someone give me a rational assessment of the differences between
the two language versions, and which one I should continue to pursue?

I'm mainly using Ruby with Rails to make basic webapps for my own
edification.

Thanks!

Alex

--
Pozdrawiam

Radosław Bułat
http://radarek.jogger.pl - mój blog

Hey Alex,
How is your learning process going? I'm currently learning Ruby also. I
picked up "Beginning Ruby" by Peter Cooper(Excellent read), and "Design
Patterns In Ruby". What kind of projects are you creating and practicing to
sharpen your skills? I need some simple projects to start creating. Do you
have any suggestions?

Thanks
Zayd

···

On Tue, Feb 3, 2009 at 12:14 PM, yuckysocks <alex.m.mcpherson@gmail.com>wrote:

Hi there,

I'm about 2 weeks into my learning attempt at Ruby (1.8.6 is what I've
cut my teeth on).

Can someone give me a rational assessment of the differences between
the two language versions, and which one I should continue to pursue?

I'm mainly using Ruby with Rails to make basic webapps for my own
edification.

Thanks!

Alex

Keep going with 1.8. There's more in 1.9 and strings are unicode.

Blog: http://random8.zenunit.com/
Learn rails: http://sensei.zenunit.com/

···

On 04/02/2009, at 4:14 AM, yuckysocks <alex.m.mcpherson@gmail.com> wrote:

Hi there,

I'm about 2 weeks into my learning attempt at Ruby (1.8.6 is what I've
cut my teeth on).

Can someone give me a rational assessment of the differences between
the two language versions, and which one I should continue to pursue?

I'm mainly using Ruby with Rails to make basic webapps for my own
edification.

Thanks!

Alex

AFAIK, Rails isn't available for 1.9 yet, and much of the good stuff in
the Ruby 1.9 APIs is actually inspired by and taken from Rails. Stick
with 1.8 for now. Learning the new stuff for 1.9 should be relatively
easy -- I've been able to move some code I've written for 1.8, and run it
on 1.9 without changes and all unit tests pass.

--Ken

···

On Tue, 03 Feb 2009 09:14:42 -0800, yuckysocks wrote:

Hi there,

I'm about 2 weeks into my learning attempt at Ruby (1.8.6 is what I've
cut my teeth on).

Can someone give me a rational assessment of the differences between the
two language versions, and which one I should continue to pursue?

I'm mainly using Ruby with Rails to make basic webapps for my own
edification.

Thanks!

Alex

--
Chanoch (Ken) Bloom. PhD candidate. Linguistic Cognition Laboratory.
Department of Computer Science. Illinois Institute of Technology.
http://www.iit.edu/~kbloom1/

unsescribe me.

···

2009/2/3, yuckysocks <alex.m.mcpherson@gmail.com>:

Hi there,

I'm about 2 weeks into my learning attempt at Ruby (1.8.6 is what I've
cut my teeth on).

Can someone give me a rational assessment of the differences between
the two language versions, and which one I should continue to pursue?

I'm mainly using Ruby with Rails to make basic webapps for my own
edification.

Thanks!

Alex

--
Jawad ZOULGAMI
Omnidata
74,Bd Abdelmoumen
20100 Casablanca - Maroc
Gsm: +212 (0) 67 43 25 78
jzoulgami@omnidata.ma
www.omnidata.co.ma

So since these changes have been made, will us noobs be hurting ourselves
starting off learning 1.8.6? Books to learn from are teaching from 1.8.

thanks

···

2009/2/3 Radosław Bułat <radek.bulat@gmail.com>

On Tue, Feb 3, 2009 at 6:14 PM, yuckysocks <alex.m.mcpherson@gmail.com> > wrote:
> Hi there,
>
> I'm about 2 weeks into my learning attempt at Ruby (1.8.6 is what I've
> cut my teeth on).
>
> Can someone give me a rational assessment of the differences between
> the two language versions, and which one I should continue to pursue?
>
> I'm mainly using Ruby with Rails to make basic webapps for my own
> edification.
>
> Thanks!
>
> Alex
>
>

Very short answer:
- new virtual machine (previously just AST interpreter)
- memory diet for some objects (Object, Array, String etc)
- improved speed (see

The Great Ruby Shootout (December 2008) | Programming Zen
)
- added character encoding support (previously works only with raw bytes)
- new syntax for hashes with symbols as keys, hashes preserve keys order
- many changes to API (improved, added consistency, removed deprecated code
etc)
- changes in language semantics (for example block arguments now works
(almost?) the same as method arguments)
- new lambda literal: ->
- external iterators (class Enumerator) now are built in
- new concept such a fiber (class Fiber)
- native threads (but with GIL like python)
- rubygems, rake are built in
- minitest supercedes old test/unit

--
Pozdrawiam

Radosław Bułat
http://radarek.jogger.pl - mój blog

You might try some of the easier questions from Ruby Quiz:

   http://rubyquiz.com/

The problems a bunch of people solved are generally the easiest. For example, have a look at:

   Ruby Quiz - LCD Numbers (#14)

and:

   Ruby Quiz - pp Pascal (#84)

James Edward Gray II

···

On Feb 3, 2009, at 1:05 PM, Zayd Abdullah wrote:

I need some simple projects to start creating. Do you have any suggestions?

I don't think so. I can name only one thing (Symbol#to_proc) which was
popularized by rails (and even not invented by rails itself).

···

On Thu, Feb 5, 2009 at 4:09 AM, Ken Bloom <kbloom@gmail.com> wrote:

AFAIK, Rails isn't available for 1.9 yet, and much of the good stuff in
the Ruby 1.9 APIs is actually inspired by and taken from Rails.

--
Pozdrawiam

Radosław Bułat
http://radarek.jogger.pl - mój blog

Hi --

So since these changes have been made, will us noobs be hurting ourselves
starting off learning 1.8.6? Books to learn from are teaching from 1.8.

If you can wait about 1.5 months or so you can read "The Well-Grounded
Rubyist" (already available in early-access PDF), which is about
1.9.1. See http://www.manning.com/black2\. Meanwhile there's a ton of
stuff you can learn in 1.8.6 that hasn't changed, or where the changes
are likely to make more sense to you anyway (like "abc"[0] being "a"
rather than 97).

See also my recent blog posts on 1.8/1.9:

http://dablog.rubypal.com/2009/1/14/10-things-to-be-aware-of-in-moving-to-ruby-1-9
http://dablog.rubypal.com/2009/1/16/son-of-10-things-to-be-aware-of-in-ruby-1-9

David

···

On Wed, 4 Feb 2009, Zayd Abdullah wrote:

--
David A. Black / Ruby Power and Light, LLC
Ruby/Rails consulting & training: http://www.rubypal.com
Coming in 2009: The Well-Grounded Rubyist (http://manning.com/black2\)

http://www.wishsight.com => Independent, social wishlist management!

Not all books. Take a look at Programming 1.9 by Pragmatic Programmers
(http://preview.tinyurl.com/7xfvk7\). They constantly update their PDF
books to keep in step with the latest changes to Ruby.

Good luck.

···

2009/2/3 Zayd Abdullah <devrubygem@gmail.com>

So since these changes have been made, will us noobs be hurting ourselves
starting off learning 1.8.6? Books to learn from are teaching from 1.8.

thanks

2009/2/3 Radosław Bułat <radek.bulat@gmail.com>

> On Tue, Feb 3, 2009 at 6:14 PM, yuckysocks <alex.m.mcpherson@gmail.com> > > wrote:
> > Hi there,
> >
> > I'm about 2 weeks into my learning attempt at Ruby (1.8.6 is what I've
> > cut my teeth on).
> >
> > Can someone give me a rational assessment of the differences between
> > the two language versions, and which one I should continue to pursue?
> >
> > I'm mainly using Ruby with Rails to make basic webapps for my own
> > edification.
> >
> > Thanks!
> >
> > Alex
> >
> >
>
> Very short answer:
> - new virtual machine (previously just AST interpreter)
> - memory diet for some objects (Object, Array, String etc)
> - improved speed (see
>
> The Great Ruby Shootout (December 2008) | Programming Zen
> )
> - added character encoding support (previously works only with raw bytes)
> - new syntax for hashes with symbols as keys, hashes preserve keys order
> - many changes to API (improved, added consistency, removed deprecated code
> etc)
> - changes in language semantics (for example block arguments now works
> (almost?) the same as method arguments)
> - new lambda literal: ->
> - external iterators (class Enumerator) now are built in
> - new concept such a fiber (class Fiber)
> - native threads (but with GIL like python)
> - rubygems, rake are built in
> - minitest supercedes old test/unit
>
>
> --
> Pozdrawiam
>
> Radosław Bułat
> http://radarek.jogger.pl - mój blog
>
>

No, you will be fine. It's not a super tough transition when you are ready.

James Edward Gray II

···

On Feb 3, 2009, at 12:52 PM, Zayd Abdullah wrote:

So since these changes have been made, will us noobs be hurting ourselves starting off learning 1.8.6? Books to learn from are teaching from 1.8.

Hi,

···

On Feb 3, 2009, at 12:52 PM, Zayd Abdullah wrote:

Books to learn from are teaching from 1.8.

In addition to those already mentioned in this thread, Flanagan's _The Ruby Programming Language_ (O'Reilly) is a great book in general and touched on Ruby 1.9 even though it was published over a year ago. It's not completely up to date with 1.9.1, but covers many of the conceptual changes.

Stephen

James Gray wrote:

···

On Feb 3, 2009, at 1:05 PM, Zayd Abdullah wrote:

I need some simple projects to start creating. Do you have any
suggestions?

You might try some of the easier questions from Ruby Quiz:

   http://rubyquiz.com/

The problems a bunch of people solved are generally the easiest. For
example, have a look at:

   Ruby Quiz - LCD Numbers (#14)

and:

   Ruby Quiz - pp Pascal (#84)

James Edward Gray II

Thanks James I will try some of the easier ones :slight_smile:
--
Posted via http://www.ruby-forum.com/\.

I think things are looking up for Ruby 1.9 books, actually. Here's
the path I'd recommend (with some obvious bias)

= To grasp the fundamentals

"The Well Grounded Rubyist" [0]

= To understand the details

"Programming Ruby 1.9" [1] and/or "The Ruby Programming Language" [2]

= To use Ruby effectively

"Ruby Best Practices" [3]

···

2009/2/3 Zayd Abdullah <devrubygem@gmail.com>:

So since these changes have been made, will us noobs be hurting ourselves
starting off learning 1.8.6? Books to learn from are teaching from 1.8.

----

This will give you a very well rounded experience, and once you
understand Ruby 1.9, quite a bit of your knowledge will still transfer
smoothly back to 1.8.
Most of these books are in Beta right now, all except [2], but if you
pick them up know you will help us catch problems before we go to
print, improving the situation for those taking the plunge directly
into Ruby 1.9.

-greg

[0] The Well-Grounded Rubyist
[1] Pragmatic Bookshelf: By Developers, For Developers
[2] http://oreilly.com/catalog/9780596516178/
[3] http://rubybestpractices.com

Hi --

···

On Thu, 5 Feb 2009, Radosław Bułat wrote:

On Thu, Feb 5, 2009 at 4:09 AM, Ken Bloom <kbloom@gmail.com> wrote:

AFAIK, Rails isn't available for 1.9 yet, and much of the good stuff in
the Ruby 1.9 APIs is actually inspired by and taken from Rails.

I don't think so. I can name only one thing (Symbol#to_proc) which was
popularized by rails (and even not invented by rails itself).

There's also #each_with_object.

David

--
David A. Black / Ruby Power and Light, LLC
Ruby/Rails consulting & training: http://www.rubypal.com
Coming in 2009: The Well-Grounded Rubyist (http://manning.com/black2\)

http://www.wishsight.com => Independent, social wishlist management!

Radosław Bułat wrote:

···

On Thu, Feb 5, 2009 at 4:09 AM, Ken Bloom <kbloom@gmail.com> wrote:

AFAIK, Rails isn't available for 1.9 yet, and much of the good stuff in
the Ruby 1.9 APIs is actually inspired by and taken from Rails.

I don't think so. I can name only one thing (Symbol#to_proc) which was
popularized by rails (and even not invented by rails itself).

HashWithIndifferentAccess?

Thanks Guys. So in a short list, what should be the features to stay away
from in 1.8, I just purchased "Beginning Ruby" by Peter Cooper, I really
would hate to struggle trying to get something then find out its no longer
needed or being used in 1.9 lol.

Thanks

···

2009/2/3 Jonathon Brenner <jonbrenner@gmail.com>

Not all books. Take a look at Programming 1.9 by Pragmatic Programmers
(http://preview.tinyurl.com/7xfvk7\). They constantly update their PDF
books to keep in step with the latest changes to Ruby.

Good luck.

2009/2/3 Zayd Abdullah <devrubygem@gmail.com>
>
> So since these changes have been made, will us noobs be hurting ourselves
> starting off learning 1.8.6? Books to learn from are teaching from 1.8.
>
> thanks
>
> 2009/2/3 Radosław Bułat <radek.bulat@gmail.com>
>
> > On Tue, Feb 3, 2009 at 6:14 PM, yuckysocks < > alex.m.mcpherson@gmail.com> > > > wrote:
> > > Hi there,
> > >
> > > I'm about 2 weeks into my learning attempt at Ruby (1.8.6 is what
I've
> > > cut my teeth on).
> > >
> > > Can someone give me a rational assessment of the differences between
> > > the two language versions, and which one I should continue to pursue?
> > >
> > > I'm mainly using Ruby with Rails to make basic webapps for my own
> > > edification.
> > >
> > > Thanks!
> > >
> > > Alex
> > >
> > >
> >
> > Very short answer:
> > - new virtual machine (previously just AST interpreter)
> > - memory diet for some objects (Object, Array, String etc)
> > - improved speed (see
> >
> >
The Great Ruby Shootout (December 2008) | Programming Zen
> > )
> > - added character encoding support (previously works only with raw
bytes)
> > - new syntax for hashes with symbols as keys, hashes preserve keys
order
> > - many changes to API (improved, added consistency, removed deprecated
code
> > etc)
> > - changes in language semantics (for example block arguments now works
> > (almost?) the same as method arguments)
> > - new lambda literal: ->
> > - external iterators (class Enumerator) now are built in
> > - new concept such a fiber (class Fiber)
> > - native threads (but with GIL like python)
> > - rubygems, rake are built in
> > - minitest supercedes old test/unit
> >
> >
> > --
> > Pozdrawiam
> >
> > Radosław Bułat
> > http://radarek.jogger.pl - mój blog
> >
> >

WHEW!! :slight_smile: okay cool

Thanks

···

On Tue, Feb 3, 2009 at 2:10 PM, James Gray <james@grayproductions.net>wrote:

On Feb 3, 2009, at 12:52 PM, Zayd Abdullah wrote:

So since these changes have been made, will us noobs be hurting ourselves

starting off learning 1.8.6? Books to learn from are teaching from 1.8.

No, you will be fine. It's not a super tough transition when you are
ready.

James Edward Gray II

No, it looks like this went from Ruby 1.9 TO Rails

http://rails.lighthouseapp.com/projects/8994/tickets/962-injecting-on-enumerable

···

2009/2/5 David A. Black <dblack@rubypal.com>

Hi --

On Thu, 5 Feb 2009, Radosław Bułat wrote:

On Thu, Feb 5, 2009 at 4:09 AM, Ken Bloom <kbloom@gmail.com> wrote:

AFAIK, Rails isn't available for 1.9 yet, and much of the good stuff in
the Ruby 1.9 APIs is actually inspired by and taken from Rails.

I don't think so. I can name only one thing (Symbol#to_proc) which was
popularized by rails (and even not invented by rails itself).

There's also #each_with_object.

--
Rick DeNatale

Blog: http://talklikeaduck.denhaven2.com/
Twitter: http://twitter.com/RickDeNatale