tag:blogger.com,1999:blog-34926058.post9172491408844867506..comments2020-11-05T19:55:50.110-08:00Comments on DSO Guy: Programming by Wishful ThinkingSteve Harrishttp://www.blogger.com/profile/17342689039838434111noreply@blogger.comBlogger11125tag:blogger.com,1999:blog-34926058.post-27820432725496055242009-12-29T08:08:47.552-08:002009-12-29T08:08:47.552-08:00Its funny. I am reading 'Everyday-Scripting...Its funny. I am reading 'Everyday-Scripting' too and I am thankful that I got a name for this technique which I like a lot.<br />In fact, my first aha moment in software design was when I discovered this technique on my own.<br /><br />RajivRajiv Abrahamhttps://www.blogger.com/profile/06630110531969098915noreply@blogger.comtag:blogger.com,1999:blog-34926058.post-16909217822485653842008-12-23T08:01:00.000-08:002008-12-23T08:01:00.000-08:00I'm the author of the book cited. I got the name f...I'm the author of the book cited. I got the name from Abelson and Sussman. (Don't want anyone to think I claimed the phrase was original to me, much less the idea.) <BR/><BR/>I do like "wishful thinking" over other descriptions, though, because it promotes the right Devil-may-care attitude: "Why *of course* the perfect method for me exists, so I'll write my code the way it should be, rather than distort it to meet what's available... Oh rats, it doesn't exist. Guess I'll have to write an adapter."Anonymousnoreply@blogger.comtag:blogger.com,1999:blog-34926058.post-76934674160513211772007-02-01T04:09:00.000-08:002007-02-01T04:09:00.000-08:00Intention-Revealing Interfaces
may be.See DDD<b>Intention-Revealing Interfaces</b><br />may be.See DDDwindedgehttps://www.blogger.com/profile/05946626693656232684noreply@blogger.comtag:blogger.com,1999:blog-34926058.post-23917794785232850062007-01-31T23:27:00.000-08:002007-01-31T23:27:00.000-08:00wow, pair programming with Peter Seibel must've be...wow, pair programming with Peter Seibel must've been a blast. His book on lisp (PCL: Practical Common Lisp) is probably one of the best programming books ever written. And wishful thinking is praised by Gerald Jay Sussman (co-authored, with Hal Abelsson, the book 'Structure and Interpretation of Computer Programs') as a foundation of programming (he shows it off using Scheme though). Wishful thinking is extremely easy on Lisp, specially because it lets you go beyond the actual language, if it imposes limitations to you.<br /><br />Not that you didnt know that already (if you paired programmed with Seibel, you probably know :D ) but well, comments are for everybody. <br /><br />As some grandmother probably said somewhere sometime: "Nothing new under the sun". All you have to do is give it a name :)asdfasdfasdfhttps://www.blogger.com/profile/04462527630247614761noreply@blogger.comtag:blogger.com,1999:blog-34926058.post-35723363509079451702007-01-28T20:48:00.000-08:002007-01-28T20:48:00.000-08:00I think the top down thing does sound quite simila...I think the top down thing does sound quite similar though more at a sub-system level. This strategy is super important when building a complex system. I usually dummy up interfaces and basic implementations of things in order to pass tests while I'm building a multi subsystem app/framework.<br /><br />The test driven design thing while also a very useful concept feels a bit different. I tend to do this kind of stuff in response to a test I may have written to help me sort through what I want an algorithm to do. Maybe my example wasn't good.Steve Harrishttps://www.blogger.com/profile/17342689039838434111noreply@blogger.comtag:blogger.com,1999:blog-34926058.post-41488276424867115102007-01-28T20:23:00.000-08:002007-01-28T20:23:00.000-08:00I don't think anyone was saying this is new. I was...I don't think anyone was saying this is new. I was only pointing out two things:<br /><br />1) That I didn't know it had a name<br />2) That I have found it useful<br /><br />I used to do a bit of Smalltalk back then too. It's a lot of fun. Probably why I picked up the Ruby bookSteve Harrishttps://www.blogger.com/profile/17342689039838434111noreply@blogger.comtag:blogger.com,1999:blog-34926058.post-81456819879784165232007-01-28T20:21:00.001-08:002007-01-28T20:21:00.001-08:00I think test driven design takes this a step furth...I think test driven design takes this a step further - instead of writing actual production code that uses methods that you haven't implemented yet, you write tests first that do so. This can really help you think through what API is needed as you're not just writing code that uses the API, but you actually think about edge cases and so on too.<br /><br />A step further from this is doctest based programming, where instead of writing a normal test, you write developer documentation with test fragments embedded. This helps you focus on what API is needed even more, in my experience.<br /><br />http://en.wikipedia.org/wiki/Doctest<br /><br />I especially like the option where doctests are embedded in .txt files, as these are developer documentation. Often not <i>great</i> developer documentation, but a lot better than <i>no</i> developer documentation, which tends to be the alternative.<br /><br />Note that test-first programming or doctest-first programming is actually a process of co-evolution. I start out writing a doctest txt file describing what I want, then implement a bit, revise my doctest as I think things through, revise the code, extend the doctest, extend the code, and so on.Martijn Faassenhttps://www.blogger.com/profile/11607525062261059367noreply@blogger.comtag:blogger.com,1999:blog-34926058.post-81368456638684581172007-01-28T20:21:00.000-08:002007-01-28T20:21:00.000-08:00I thought it was called "top down"
http://en.wikip...I thought it was called "top down"<br />http://en.wikipedia.org/wiki/Top_downAnonymoushttps://www.blogger.com/profile/13210877729806177094noreply@blogger.comtag:blogger.com,1999:blog-34926058.post-6568247431540655372007-01-28T19:45:00.000-08:002007-01-28T19:45:00.000-08:00I was taught to program using this style about 10 ...I was taught to program using this style about 10 years ago in my introductory programming course where Smalltalk was the language of instruction.Unknownhttps://www.blogger.com/profile/12035857447356935907noreply@blogger.comtag:blogger.com,1999:blog-34926058.post-74075337713916386402007-01-28T04:08:00.000-08:002007-01-28T04:08:00.000-08:00Actually, this method is quite common (what I know...Actually, this method is quite common (what I know, at least I use it and some of my colleagues).<br />Thus, I would call it "intentional" rather than "wishful".<br />--<br />To give a sort of strange and maybe too far analogy: Test-Driven Development (TDD) is about writing your tests first, and then caring about the business logic.<br />--<br />I think, coming from a high-level view and then going down to a more detailled level is a natural way for organized persons :-)Javarunnerhttps://www.blogger.com/profile/15916288787104995381noreply@blogger.comtag:blogger.com,1999:blog-34926058.post-7002441091096231302007-01-28T01:18:00.000-08:002007-01-28T01:18:00.000-08:00All the time! Thanks for posting this I also didn'...All the time! Thanks for posting this I also didn't know that it has a name.Adamhttps://www.blogger.com/profile/06069513893717665605noreply@blogger.com