How to Design Classes (in Ruby, Python, Java or any OOP)
1–10 of 26 posts
Re: How to Design Classes (in Ruby, Python, Java or any OOP)
#2Re: How to Design Classes (in Ruby, Python, Java or any OOP)
#3This looks like a great book, but I'm not sure it really represents a good way to learn how to design classes in Ruby or Python. It seems heavily biased towards designing classes in a statically-typed, non-type-inferring, java-style language. Programming in Python is a lot more about knowing when defining a new class (rather than using built-in types and classes) even a good idea to begin with.
Then again I also feel a little dirty for comparing the likes of Tchaikovsky and Beethoven to Java...
Re: How to Design Classes (in Ruby, Python, Java or any OOP)
#4This looks like a great book, but I'm not sure it really represents a good way to learn how to design classes in Ruby or Python. It seems heavily biased towards designing classes in a statically-typed, non-type-inferring, java-style language. Programming in Python is a lot more about knowing when defining a new class (rather than using built-in types and classes) even a good idea to begin with.
I shamelessly clicked away as soon as I realized it was Java. Well, not completely shamelessly. I kind of feel like a "rassa-frackin' whippersnapper" disgustedly changing the radio station when stumbling on classical orchestral music. Then again I also feel a little dirty for comparing the likes of Tchaikovsky and Beethoven to Java...
As the author said, this book is NOT about Java. Similarly, SICP is NOT about Scheme.
Interestingly, It's the same author who teaches how to design programs with Racket, a lisp dialect.
Re: How to Design Classes (in Ruby, Python, Java or any OOP)
#5Earlier quoted context omitted.
I shamelessly clicked away as soon as I realized it was Java. Well, not completely shamelessly. I kind of feel like a "rassa-frackin' whippersnapper" disgustedly changing the radio station when stumbling on classical orchestral music. Then again I also feel a little dirty for comparing the likes of Tchaikovsky and Beethoven to Java...
This book takes a theoretical approach to OOP. As the author said, this book is NOT about Java. Similarly, SICP is NOT about Scheme. Interestingly, It's the same author who teaches how to design programs with Racket, a lisp dialect. http://www.ccs.neu.edu/home/matthias/HtDP2e/index.html
Re: How to Design Classes (in Ruby, Python, Java or any OOP)
#6This looks like a great book, but I'm not sure it really represents a good way to learn how to design classes in Ruby or Python. It seems heavily biased towards designing classes in a statically-typed, non-type-inferring, java-style language. Programming in Python is a lot more about knowing when defining a new class (rather than using built-in types and classes) even a good idea to begin with.
I shamelessly clicked away as soon as I realized it was Java. Well, not completely shamelessly. I kind of feel like a "rassa-frackin' whippersnapper" disgustedly changing the radio station when stumbling on classical orchestral music. Then again I also feel a little dirty for comparing the likes of Tchaikovsky and Beethoven to Java...
Re: How to Design Classes (in Ruby, Python, Java or any OOP)
#7Earlier quoted context omitted.
This book takes a theoretical approach to OOP. As the author said, this book is NOT about Java. Similarly, SICP is NOT about Scheme. Interestingly, It's the same author who teaches how to design programs with Racket, a lisp dialect. http://www.ccs.neu.edu/home/matthias/HtDP2e/index.html
The book opens with "What you'll learn: Java."
From the author:
"It is a good idea to study the programming language that you use on a daily basis and to learn as much as possible about it. We strongly believe, however, that it is a bad idea to teach the details of any programming language in a course. Nobody can predict which programming language you will use.
Therefore, time in a course is better spent on studying the general principles of program design rather than the arcane principles of any given programming language."
Re: How to Design Classes (in Ruby, Python, Java or any OOP)
#8Re: How to Design Classes (in Ruby, Python, Java or any OOP)
#9Earlier quoted context omitted.
I shamelessly clicked away as soon as I realized it was Java. Well, not completely shamelessly. I kind of feel like a "rassa-frackin' whippersnapper" disgustedly changing the radio station when stumbling on classical orchestral music. Then again I also feel a little dirty for comparing the likes of Tchaikovsky and Beethoven to Java...
No, this is quite right. Classical music is as bloated, heavy-handed, and decadent as Java. Good music is found in the 16th century and earlier, and in the 20th century and later. We can see this maps to software: good ideas are to be found in the 70s and earlier, and in some hoped-for new era yet to come . . .
Re: How to Design Classes (in Ruby, Python, Java or any OOP)
#10Earlier quoted context omitted.
I shamelessly clicked away as soon as I realized it was Java. Well, not completely shamelessly. I kind of feel like a "rassa-frackin' whippersnapper" disgustedly changing the radio station when stumbling on classical orchestral music. Then again I also feel a little dirty for comparing the likes of Tchaikovsky and Beethoven to Java...
This book takes a theoretical approach to OOP. As the author said, this book is NOT about Java. Similarly, SICP is NOT about Scheme. Interestingly, It's the same author who teaches how to design programs with Racket, a lisp dialect. http://www.ccs.neu.edu/home/matthias/HtDP2e/index.html
That's what it says, but the concepts covered are so java-oriented it may as well be.
It uses generic language to describe most of the concepts, but the underlying assumption seems to be that you need to understand these concepts because you need to program in Java, C#, C++, or some other closely-related language with no dynamic typing, no first-class functions, and explicit java-style semantics for abstract classes, interfaces, public vs private methods, implements vs extends, and such.
Much of that is invisible in a language like Python, and a book that laboriously covers each concept in the context of a language where you have to specify everything explicitly probably isn't going to make you much better at writing classes in python. Or if it is, it's going to be a lot of work for minimal benefit.
> Interestingly, It's the same author who teaches how to design programs with Racket, a lisp dialect.
Indeed, that's partly why I'm surprised the book takes the approach it does. However, it does seem to be a good, thorough book (ignoring the missing sections) if you need to design classes in Java or C# (which covers a lot of people).