<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
	>

<channel>
	<title>The ByteBaker</title>
	<atom:link href="http://bytebaker.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://bytebaker.com</link>
	<description>Computer Science isn&#039;t a science and it&#039;s not about computers</description>
	<lastBuildDate>Tue, 24 Aug 2010 13:12:37 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.com/</generator>
<cloud domain='bytebaker.com' port='80' path='/?rsscloud=notify' registerProcedure='' protocol='http-post' />
<image>
		<url>http://0.gravatar.com/blavatar/6d47d9dd6b113f7f539237c5cff8cd54?s=96&#038;d=http://s2.wp.com/i/buttonw-com.png</url>
		<title>The ByteBaker</title>
		<link>http://bytebaker.com</link>
	</image>
	<atom:link rel="search" type="application/opensearchdescription+xml" href="http://bytebaker.com/osd.xml" title="The ByteBaker" />
	<atom:link rel='hub' href='http://bytebaker.com/?pushpress=hub'/>
		<item>
		<title>Everything is public</title>
		<link>http://bytebaker.com/2010/08/24/everything-is-public/</link>
		<comments>http://bytebaker.com/2010/08/24/everything-is-public/#comments</comments>
		<pubDate>Tue, 24 Aug 2010 13:12:37 +0000</pubDate>
		<dc:creator>Shrutarshi Basu</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[object-orientation Java C++ Ruby message-passing]]></category>

		<guid isPermaLink="false">http://bytebaker.com/?p=1176</guid>
		<description><![CDATA[Steve Yegge started blogging again recently and his second post back (which is almost a month old by now) is essentially a parody of Java&#8217;s access specifier system and the prevalence of the &#8220;private&#8221; attribute. The debate over public vs private comes up every now now and then in object-oriented programming and has its fair [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1176&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Steve Yegge started blogging again recently and <a href="http://steve-yegge.blogspot.com/2010/07/wikileaks-to-leak-5000-open-source-java.html">his second post back</a> (which is almost a month old by now) is essentially a parody of Java&#8217;s access specifier system and the prevalence of the &#8220;private&#8221; attribute. The debate over public vs private comes up every now now and then in object-oriented programming and has its fair share of people on either side of the line. So when Steve suggested that private just go away (or seemed to suggest that anyway) he of course got attacked with counter-examples and all sorts of cases where private is helpful.</p>
<p>Saying that everything should be public is certainly an idea that takes getting used to. It&#8217;s like saying that you should publish the details of your drunken escapades on your blog. It&#8217;s unsettling, but then again, the pictures are probably already on Facebook anyway. I think there are two issues here &#8212; one is for fields, and the other is for methods.</p>
<p>Though Steve seems to say that fields should be public (or have getters and setters on them), I personally tend to go the other way: fields should be private by default and only accessible through getters and setters. I like the way Ruby does it &#8212; everything is private by default but the accessors are generated by metaprogramming, so you don&#8217;t have the junk lines of getWhatever and setWhatever that you do with Java. Direct field accesses like Java and C++ allow are just bad ideas.</p>
<p>For methods things are the other way around. Firstly, I don&#8217;t like the idea of invoking methods on an object. I far prefer the Smalltalk notion of sending messages to objects and having them respond. I think it&#8217;s a far better conceptual model than methods and the private/public debate goes away in that model. If your object responds to methods, then being able to use private and public means that the object knows of and cares about where about the message is coming from. However, this breaks encapsulation. Ideally an object should respond to a particular message the same way irrespective of where the message comes from.</p>
<p>But, you say, what of the real world where ideals don&#8217;t necessarily hold? Hmm&#8230; let&#8217;s see what happens to software development under the assumption that all your methods and functions are callable from outside. To start off, you have to be careful about what parameters your methods take. You can&#8217;t assume that they&#8217;ve been pre-sanitized which means that either you&#8217;ll have to check them yourself or fail cleanly (and maybe send a stern warning up the chain). This may be a bit annoying, but I&#8217;d say it&#8217;s on the same level as dynamic typing &#8212; you&#8217;re never 100% sure of what type the arguments are so you take appropriate measures.</p>
<p>Now let&#8217;s talk about safety. One of the arguments in favor of private is that you don&#8217;t want methods to be abused and put the object in an unusable state. Again, I don&#8217;t think this is as big of a problem as it&#8217;s made up to be. It just involves rearranging where checking occurs. Presumably, if you have a private method that makes delicate changes to your object, you have a public method somewhere else that approves the changes and then calls said private method. Why not put the approval inside the private method and dispense with the public method entirely? If you want to make a change to an object, call a method to do it. If it works, fine. If not you get an error back.</p>
<p>I should make it clear at this point, that I don&#8217;t have any real world example to back up my claim (at least no examples that aren&#8217;t hopelessly contrived). What I&#8217;m talking is refactoring to meet a design constraint &#8212; that of total publicness. People will kick and scream and say that it breaks their careful separation of functionality into methods, but I think it&#8217;s just a design pattern, like dependency injection for example. And the trade-off to that is probably more flexible, more powerful software systems.</p>
<p>If everything is public (and designed from the ground up to be public) you start writing code that&#8217;s meant to be used by other code. Which in turn makes it easier to use and extend your code. I think you&#8217;ll eventually end up with something like Emacs &#8212; lots of public functions that do useful things to an object (the text in the editor) and an awesome array of functionality made possible by using these public functions. There is a fundamental change in programming and building ideology that needs to take place. With full publicness you can&#8217;t have a nicely bureaucratic language like Java. You&#8217;re going to end up with something that&#8217;s far more open and flexible like Ruby, Python or *shudder* Lisp.</p>
<p>I think that a lot of the heightened discussion surrounding Steve&#8217;s suggestion stems from the nature of the Java language. It&#8217;s certainly meant to be used by large corporate teams and is designed to stop programmers from hurting themselves (or stepping onto someone else&#8217;s turf). &#8220;Bureaucratic&#8221; is perhaps the best way to describe the language. If you take out private from a language like that, you lose most of its raison d&#8217;etre. So is private a good thing? Probably not. Does it need to stay in Java? Probably.</p>
<p>I&#8217;d like to reiterate that I think that message-passing is a superior way to think about object-orientation and it makes the public/private debate unnecessary. That&#8217;s why the language I&#8217;m building for my thesis will have message-passing. I&#8217;m also stealing Ruby&#8217;s private-by-default and metaprogramming for accessors.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/bytebaker.wordpress.com/1176/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/bytebaker.wordpress.com/1176/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/bytebaker.wordpress.com/1176/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/bytebaker.wordpress.com/1176/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/bytebaker.wordpress.com/1176/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/bytebaker.wordpress.com/1176/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/bytebaker.wordpress.com/1176/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/bytebaker.wordpress.com/1176/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/bytebaker.wordpress.com/1176/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/bytebaker.wordpress.com/1176/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/bytebaker.wordpress.com/1176/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/bytebaker.wordpress.com/1176/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/bytebaker.wordpress.com/1176/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/bytebaker.wordpress.com/1176/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1176&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://bytebaker.com/2010/08/24/everything-is-public/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fcafd7571cc4c82dd3e31c7e728eb2d9?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Basu</media:title>
		</media:content>
	</item>
		<item>
		<title>Sunday Selection 2010-08-22</title>
		<link>http://bytebaker.com/2010/08/22/sunday-selection-2010-08-22/</link>
		<comments>http://bytebaker.com/2010/08/22/sunday-selection-2010-08-22/#comments</comments>
		<pubDate>Sun, 22 Aug 2010 13:55:26 +0000</pubDate>
		<dc:creator>Shrutarshi Basu</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://bytebaker.com/?p=1172</guid>
		<description><![CDATA[Reading The James Franco Project This has nothing to do with computers, technology or programming. James Franco is an actor who is leading a very full life &#8212; he&#8217;s acting full time (on multiple projects) while working on multiple graduate degrees at different places around the country. Certainly not something that&#8217;s recommended for everyone, but [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1172&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><strong>Reading</strong></p>
<p><a href="http://nymag.com/movies/profiles/67284/">The James Franco Project</a> This has nothing to do with computers, technology or programming. James Franco is an actor who is leading a very full life &#8212; he&#8217;s acting full time (on multiple projects) while working on multiple graduate degrees at different places around the country. Certainly not something that&#8217;s recommended for everyone, but it goes to show just how much one man can do if he puts his mind to it.</p>
<p><strong>Media</strong></p>
<p><a href="http://vimeo.com/7917568">Dieter Rams &#8211; More is Less</a> The design of technological objects has always fascinated me and Jonathan Ives might be the design man of the current times, but this video shows off Dieter Rams&#8217; work and some of his key insights and you can see them reflected in the modern gadgets that we consider to be attractive.</p>
<p><span style='text-align:center; display: block;'>
<object type="application/x-shockwave-flash" width="400" height="300" data="http://www.vimeo.com/moogaloop.swf?clip_id=7917568&amp;server=www.vimeo.com&amp;fullscreen=1&amp;show_title=1&amp;show_byline=0&amp;show_portrait=0&amp;color=01AAEA">
	<param name="quality" value="best" />
	<param name="allowfullscreen" value="true" />
	<param name="scale" value="showAll" />
	<param name="movie" value="http://www.vimeo.com/moogaloop.swf?clip_id=7917568&amp;server=www.vimeo.com&amp;fullscreen=1&amp;show_title=1&amp;show_byline=0&amp;show_portrait=0&amp;color=01AAEA" />
	<param name="wmode" value="opaque" />
</object>
</span></p>
<p><strong>Software</strong></p>
<p><a href="http://foursquare.com/">Foursquare</a> I&#8217;ve just recently started using Foursquare (yes, I know after Facebook announced places) which is an iPhone, Android and Blackberry app that lets you &#8220;check-in&#8221; to places you visit and gather points for traveling and visiting. It&#8217;s a fun little utility and makes for interesting games with friends (and probably helps generated revenue for local businesses). I&#8217;m hesitant to say if it&#8217;s actually useful, but it&#8217;s definitely worth trying out.</p>
<p>Note: I find that I&#8217;m starting to explore less and less and am considering retiring the software section in upcoming weeks. Let me know if you have any suggestions.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/bytebaker.wordpress.com/1172/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/bytebaker.wordpress.com/1172/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/bytebaker.wordpress.com/1172/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/bytebaker.wordpress.com/1172/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/bytebaker.wordpress.com/1172/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/bytebaker.wordpress.com/1172/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/bytebaker.wordpress.com/1172/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/bytebaker.wordpress.com/1172/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/bytebaker.wordpress.com/1172/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/bytebaker.wordpress.com/1172/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/bytebaker.wordpress.com/1172/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/bytebaker.wordpress.com/1172/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/bytebaker.wordpress.com/1172/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/bytebaker.wordpress.com/1172/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1172&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://bytebaker.com/2010/08/22/sunday-selection-2010-08-22/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fcafd7571cc4c82dd3e31c7e728eb2d9?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Basu</media:title>
		</media:content>
	</item>
		<item>
		<title>Sunday Selection 2010-08-15</title>
		<link>http://bytebaker.com/2010/08/15/sunday-selection-2010-08-15/</link>
		<comments>http://bytebaker.com/2010/08/15/sunday-selection-2010-08-15/#comments</comments>
		<pubDate>Sun, 15 Aug 2010 22:29:37 +0000</pubDate>
		<dc:creator>Shrutarshi Basu</dc:creator>
				<category><![CDATA[News]]></category>
		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://bytebaker.com/?p=1166</guid>
		<description><![CDATA[Firstly, Happy Indian Indepdence Day! Enjoy your freedom, use it well, it was hard-earned. Moving on&#8230; Reading The early history of HTML Have you ever wondered how the great World Wide Web came to be? Apparently it&#8217;s a bit of a mystery but this article does a good job of piecing things together and giving [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1166&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Firstly, Happy Indian Indepdence Day! Enjoy your freedom, use it well, it was hard-earned. Moving on&#8230;</p>
<p><strong>Reading</strong></p>
<p><a href="http://infomesh.net/html/history/early/">The early history of HTML</a> Have you ever wondered how the great World Wide Web came to be? Apparently it&#8217;s a bit of a mystery but this article does a good job of piecing things together and giving some insight into how HTML.</p>
<p><a href="http://www.paulgraham.com/yahoo.html">What happened to Yahoo!</a> Even though Yahoo still exists and owns some really great websites (like Delicious and Flickr), it seems to have completely dropped off the map in recent years. Paul Graham (whose startup was bought by Yahoo!) takes a look at why Yahoo! seems to have lost its relevance.</p>
<p><strong>Media</strong></p>
<p><a href="http://www.livestream.com/nytechmeetup/video?clipId=pla_8b03ead8-b68f-4f04-9744-2e0e85274b03&amp;utm_source=lsplayer&amp;utm_medium=ui-play&amp;utm_campaign=click-bait&amp;utm_content=nytechmeetup">Twilio on NY Tech Meetup</a> It&#8217;s not that often you see people writing code live during presentations, so when you do see people whipping up live code to create usable webapps and then opening them up to the public, that&#8217;s something really worth watching.</p>
<p><strong>Software</strong></p>
<p><a href="http://www.instapaper.com/">Instapaper</a> aims to bring back the practice of reading long-form pieces of the Internet. It lets you save webpages and also helpfully extracts the text from the page. There are iPhone, iPad and Kindle apps to help you read anywhere and anytime.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/bytebaker.wordpress.com/1166/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/bytebaker.wordpress.com/1166/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/bytebaker.wordpress.com/1166/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/bytebaker.wordpress.com/1166/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/bytebaker.wordpress.com/1166/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/bytebaker.wordpress.com/1166/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/bytebaker.wordpress.com/1166/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/bytebaker.wordpress.com/1166/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/bytebaker.wordpress.com/1166/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/bytebaker.wordpress.com/1166/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/bytebaker.wordpress.com/1166/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/bytebaker.wordpress.com/1166/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/bytebaker.wordpress.com/1166/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/bytebaker.wordpress.com/1166/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1166&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://bytebaker.com/2010/08/15/sunday-selection-2010-08-15/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fcafd7571cc4c82dd3e31c7e728eb2d9?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Basu</media:title>
		</media:content>
	</item>
		<item>
		<title>I&#8217;m making a language</title>
		<link>http://bytebaker.com/2010/08/04/im-making-a-language/</link>
		<comments>http://bytebaker.com/2010/08/04/im-making-a-language/#comments</comments>
		<pubDate>Wed, 04 Aug 2010 15:27:38 +0000</pubDate>
		<dc:creator>Shrutarshi Basu</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://bytebaker.com/?p=1162</guid>
		<description><![CDATA[Or as some would say I&#8217;m starting a new religion. But no, in all seriousness I am creating a new language as  part of my senior honors thesis. Why am I doing this? Because I need a good topic for my honors thesis and programming languages are what I&#8217;m really interested in. I also want [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1162&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Or as some would say I&#8217;m starting a new religion. But no, in all seriousness I am creating a new language as  part of my senior honors thesis. Why am I doing this? Because I need a good topic for my honors thesis and programming languages are what I&#8217;m really interested in. I also want to go to grad school next year for programming languages and I think the best way for me to learn about languages is to make one from the bottom up.</p>
<p>This is the first time that I&#8217;m making my own language, but I have been studying programming languages for the last 2 to 3 years. And I want to take those lessons learned and apply them. I&#8217;m trying to strike a balance between taking the best of what&#8217;s out there and putting in original ideas. There are a lot of great ideas out there but they&#8217;re spread across lots of different languages. Some languages like Ruby do a great job of pulling together the best of what&#8217;s out there. Under normal circumstances I would be perfectly happy with building a language that does nothing new. But this is an academic honors thesis and I would be really really disappointed with myself if I didn&#8217;t contribute anything new.</p>
<p>What am I going to do that&#8217;s new? I want to solve a problem that is actually being faced by programmers on the front line and though I admire the theory behind languages, I&#8217;m more interested in implementation than pure theory. One clear problem in our field is the rise of slower, parallel processors, multicore CPUs in particular. And we have very little idea of how to use all those cores probably. There are certainly solutions that are being proposed &#8212; threads, software transactional memory, Actors, so on and so forth. But these tools are generally considered beyond the reach of everyday programmers. What most programmers are acquainted with is object-oriented programming. My idea is to take an object oriented language and make it concurrent from the bottom up. The naive idea (that I have to significantly research and refine) is that each object is its own thread of operation. This is similar to the Actor model and I&#8217;ll need to study and think more to see how to differentiate between that and what I want to do.</p>
<p>But as I said there are a lot of good languages out there with great ideas and I&#8217;m going to shamelessly take as many of them as I can. Everything will be an object, but it will be prototype-based (a la JavaScript), not class-based. Syntax-wise it will be elegant and homoiconic: that is there will be as few special syntactical constructs as possible and programs will be data structures in the language itself. This is to lay the groundwork for macros, though I probably won&#8217;t be getting to that any time soon. However, it will have first class functions from day one and I&#8217;m going to try like hell to make everything (or make it possible to make everything) first-class. And this isn&#8217;t just for functions, I want to extend it to tests, constructs and even documentation. All of these are good ideas that have been tried and tested before, I&#8217;m just combining them in a new (and hopefully better) way.</p>
<p>Technology aside, the language will be completely open source, probably under the GPL v3. As for the name, I&#8217;m probably going to call it Parley. I want a name that implies discussion. Plus it opens up a whole world of pirate-related metaphors and names for later use and I love word-play. I don&#8217;t plan on really working on it until the end of August, though I will be reading up and throwing ideas around. Code will be on Github as soon as I have something that works.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/bytebaker.wordpress.com/1162/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/bytebaker.wordpress.com/1162/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/bytebaker.wordpress.com/1162/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/bytebaker.wordpress.com/1162/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/bytebaker.wordpress.com/1162/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/bytebaker.wordpress.com/1162/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/bytebaker.wordpress.com/1162/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/bytebaker.wordpress.com/1162/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/bytebaker.wordpress.com/1162/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/bytebaker.wordpress.com/1162/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/bytebaker.wordpress.com/1162/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/bytebaker.wordpress.com/1162/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/bytebaker.wordpress.com/1162/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/bytebaker.wordpress.com/1162/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1162&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://bytebaker.com/2010/08/04/im-making-a-language/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fcafd7571cc4c82dd3e31c7e728eb2d9?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Basu</media:title>
		</media:content>
	</item>
		<item>
		<title>Sunday Selection 2010-07-25</title>
		<link>http://bytebaker.com/2010/07/25/sunday-selection-2010-07-25/</link>
		<comments>http://bytebaker.com/2010/07/25/sunday-selection-2010-07-25/#comments</comments>
		<pubDate>Sun, 25 Jul 2010 17:56:48 +0000</pubDate>
		<dc:creator>Shrutarshi Basu</dc:creator>
				<category><![CDATA[Uncategorized]]></category>

		<guid isPermaLink="false">http://bytebaker.com/?p=1155</guid>
		<description><![CDATA[Reading Emacs vs Vi is rooted in the love of Lisp &#8212; This is an older article I came across a few days which shows how the universal programming powers that define Lisp are at the root of the Emacs/Vi divide Have generics killed Java in which the authors argues that generics have harmed Java [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1155&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p><strong>Reading</strong></p>
<p><a href="http://stevengharms.com/emacs-v-vi-is-rooted-in-the-love-of-lisp">Emacs vs Vi is rooted in the love of Lisp</a> &#8212; This is an older article I came across a few days which shows how the universal programming powers that define Lisp are at the root of the Emacs/Vi divide</p>
<p><a href="http://www.artima.com/weblogs/viewpost.jsp?thread=299081">Have generics killed Java</a> in which the authors argues that generics have harmed Java and that static type checking is a dead-end</p>
<p><strong>Media</strong></p>
<p><a href="http://www.youtube.com/watch?v=5kj5ApnhPAE">Public Static Void</a> &#8212; an excellent talk by Rob Pike that discusses language and evolution and why our languages mostly suck</p>
<p><span style="text-align:center; display: block;"><a href="http://bytebaker.com/2010/07/25/sunday-selection-2010-07-25/"><img src="http://img.youtube.com/vi/5kj5ApnhPAE/2.jpg" alt="" /></a></span></p>
<p><strong>Software</strong></p>
<p><a href="http://www.azarask.in/blog/post/tabcandy/">Firefox Alpha with TabCandy</a> is an early test release that contains a very interesting new interaction interface for tabs which I think is a step forward. Now if only I could run it all from my keyboard. Be warned that no extensions will work.</p>
<p><strong>Bonus: </strong>Here&#8217;s the TabCandy video</p>
<p><span style='text-align:center; display: block;'>
<object type="application/x-shockwave-flash" width="400" height="300" data="http://www.vimeo.com/moogaloop.swf?clip_id=13560319&amp;server=www.vimeo.com&amp;fullscreen=1&amp;show_title=1&amp;show_byline=0&amp;show_portrait=0&amp;color=01AAEA">
	<param name="quality" value="best" />
	<param name="allowfullscreen" value="true" />
	<param name="scale" value="showAll" />
	<param name="movie" value="http://www.vimeo.com/moogaloop.swf?clip_id=13560319&amp;server=www.vimeo.com&amp;fullscreen=1&amp;show_title=1&amp;show_byline=0&amp;show_portrait=0&amp;color=01AAEA" />
	<param name="wmode" value="opaque" />
</object>
</span></p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/bytebaker.wordpress.com/1155/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/bytebaker.wordpress.com/1155/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/bytebaker.wordpress.com/1155/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/bytebaker.wordpress.com/1155/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/bytebaker.wordpress.com/1155/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/bytebaker.wordpress.com/1155/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/bytebaker.wordpress.com/1155/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/bytebaker.wordpress.com/1155/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/bytebaker.wordpress.com/1155/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/bytebaker.wordpress.com/1155/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/bytebaker.wordpress.com/1155/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/bytebaker.wordpress.com/1155/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/bytebaker.wordpress.com/1155/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/bytebaker.wordpress.com/1155/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1155&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://bytebaker.com/2010/07/25/sunday-selection-2010-07-25/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fcafd7571cc4c82dd3e31c7e728eb2d9?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Basu</media:title>
		</media:content>

		<media:content url="http://img.youtube.com/vi/5kj5ApnhPAE/2.jpg" medium="image" />
	</item>
		<item>
		<title>Joining the Creative Commons</title>
		<link>http://bytebaker.com/2010/07/23/the-bytebaker-is-now-in-the-creative-commons/</link>
		<comments>http://bytebaker.com/2010/07/23/the-bytebaker-is-now-in-the-creative-commons/#comments</comments>
		<pubDate>Fri, 23 Jul 2010 13:49:56 +0000</pubDate>
		<dc:creator>Shrutarshi Basu</dc:creator>
				<category><![CDATA[News]]></category>
		<category><![CDATA[creative commons]]></category>

		<guid isPermaLink="false">http://bytebaker.com/?p=1144</guid>
		<description><![CDATA[The ByteBaker by Shrutarshi Basu is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License. Permissions beyond the scope of this license may be available at http://bytebaker.com/contact. This is something I should have done a long long time ago. But as they say, better late than never. I received an email yesterday from Robert Sebescen [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1144&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<blockquote>
<p style="text-align:center;"><a rel="license" href="http://creativecommons.org/licenses/by-nc-sa/3.0/"><img style="border-width:0;" src="http://i.creativecommons.org/l/by-nc-sa/3.0/88x31.png" alt="Creative Commons License" /></a><br />
The ByteBaker by <a rel="cc:attributionURL" href="http://bytebaker.com">Shrutarshi Basu</a> is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by-nc-sa/3.0/">Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License</a>.<br />
Permissions beyond the scope of this license may be available at <a rel="cc:morePermissions" href="http://bytebaker.com/contact">http://bytebaker.com/contact</a>.</p>
</blockquote>
<p>This is something I should have done a long long time ago. But as they say, better late than never. I received an email yesterday from Robert Sebescen at <a href="http://kodknackaren.se/">Kodknackaren.se</a> offered to translate and host the posts from the Powerful Python series. I was going to say yes and then realized that though I didn&#8217;t have any sort of licensing information on The ByteBaker.</p>
<p>So today I&#8217;m changing that. All the content that I&#8217;ve written on the site is under the Creative Commons license as stated above. It basically means that you can redistribute my work and create derivative works from it (such as Sebescen&#8217;s translations) as long as you give me due credit. However, if you are <strong>not </strong>allowed to use the work for any commercial purposes (ie, you can&#8217;t sell it or charge people to see it). I&#8217;m not again people making money, I just don&#8217;t want them doing it off of my work without giving me a cut. I have contact info on this site, so if anyone&#8217;s interested, drop me a line and we&#8217;ll talk.</p>
<p>I do reverse the right to change the license in the future, however I can&#8217;t see myself doing that anytime in the near future. For readers, this isn&#8217;t really a change at all. But the great thing about computers and the Internet is that it promotes an incredibly diverse and productive remix culture. And I want to my part to give back to that remix culture that has given me so much cool stuff.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/bytebaker.wordpress.com/1144/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/bytebaker.wordpress.com/1144/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/bytebaker.wordpress.com/1144/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/bytebaker.wordpress.com/1144/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/bytebaker.wordpress.com/1144/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/bytebaker.wordpress.com/1144/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/bytebaker.wordpress.com/1144/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/bytebaker.wordpress.com/1144/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/bytebaker.wordpress.com/1144/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/bytebaker.wordpress.com/1144/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/bytebaker.wordpress.com/1144/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/bytebaker.wordpress.com/1144/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/bytebaker.wordpress.com/1144/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/bytebaker.wordpress.com/1144/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1144&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://bytebaker.com/2010/07/23/the-bytebaker-is-now-in-the-creative-commons/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fcafd7571cc4c82dd3e31c7e728eb2d9?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Basu</media:title>
		</media:content>

		<media:content url="http://i.creativecommons.org/l/by-nc-sa/3.0/88x31.png" medium="image">
			<media:title type="html">Creative Commons License</media:title>
		</media:content>
	</item>
		<item>
		<title>Revamping the ByteBaker series</title>
		<link>http://bytebaker.com/2010/07/22/revamping-the-bytebaker-series/</link>
		<comments>http://bytebaker.com/2010/07/22/revamping-the-bytebaker-series/#comments</comments>
		<pubDate>Thu, 22 Jul 2010 14:15:21 +0000</pubDate>
		<dc:creator>Shrutarshi Basu</dc:creator>
				<category><![CDATA[Internet]]></category>
		<category><![CDATA[News]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Python]]></category>
		<category><![CDATA[tumblr]]></category>
		<category><![CDATA[internet]]></category>
		<category><![CDATA[diigo]]></category>

		<guid isPermaLink="false">http://bytebaker.com/?p=1129</guid>
		<description><![CDATA[Not too long ago I started writing series of posts on The ByteBaker. I started two of them: Powerful Python and Sunday Selections. Powerful Python was a series of posts about the Python programming languages and how its features make it easier for programmers to write code. As it stands now there are four posts [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1129&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Not too long ago I started writing series of posts on The ByteBaker. I started two of them: Powerful Python and Sunday Selections.</p>
<p><a href="http://bytebaker.files.wordpress.com/2009/03/python.jpg"><img class="alignright size-full wp-image-1126" title="python" src="http://bytebaker.files.wordpress.com/2009/03/python.jpg?w=178&#038;h=242" alt="Python" width="178" height="242" /></a><a href="http://bytebaker.com/2009/03/26/powerful-python/">Powerful Python</a> was a series of posts about the Python programming languages and how its features make it easier for programmers to write code. As it stands now there are four posts in this series:</p>
<ul>
<li><a href="http://bytebaker.com/2008/07/30/python-namespaces/">A guide to  Python namespaces</a></li>
<li><a href="http://bytebaker.com/2008/11/03/switch-case-statement-in-python/">Switch-case  statement in Python</a></li>
<li><a href="http://bytebaker.com/2009/03/31/python-properties-vs-java-access-modifiers/">Python  properties vs Java Access Specifiers</a></li>
<li><a href="http://bytebaker.com/2009/08/17/switch-case-statement-in-python-revisited/">Switch-case statement in Python revisited</a></li>
</ul>
<p>Python is the language that I&#8217;m most familiar with and have written the most code in. Over the last month or so I&#8217;ve been writing Python day in day out and really exercising my Python chops (as well as getting acquainted with features like generators and decorators).  Over the next few weeks I&#8217;m going to be writing more posts exploring Python and adding them to the Powerful Python series. If you regularly write code in Python or just have a passing interest, this is something you&#8217;re going to like.</p>
<p>The second series that I had was Sunday Selections. I try to post two to three times a week, but I didn&#8217;t want to leave the weekends completely bare. I also wanted to spend my weekends doing other things (preferably away from the computer). So I started a series where every Sunday I would post links (with brief intros) to interesting things that I had found the week before. I&#8217;ll admit that I haven&#8217;t been very stable with the post schedule, partly because I kept forgetting or losing what I had found and really didn&#8217;t want to go hunting around the intertubes for whatever it is that I liked.</p>
<p>Over the past few months I&#8217;ve become much better at holding onto things I find online. Using Diigo for bookmarks and Tumblr for &#8220;scrapbooking&#8221; the web I&#8217;ve been managing to keep a good record of all the wonderful stuff I&#8217;ve found (and there is a lot of it). So I&#8217;m bringing back Sunday Selections as well (starting this Sunday) so stay tuned for a steady flow of Internet-y goodness.</p>
<p>I&#8217;m really looking forward to writing series posts again. I feel like my writing can sometimes get either monotonous or spread all over the place without any focus. I&#8217;m hoping that the series (especially the Powerful Python series) will provide a good path for me to write articles that are coherent and progress along a definite line. Stay tuned.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/bytebaker.wordpress.com/1129/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/bytebaker.wordpress.com/1129/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/bytebaker.wordpress.com/1129/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/bytebaker.wordpress.com/1129/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/bytebaker.wordpress.com/1129/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/bytebaker.wordpress.com/1129/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/bytebaker.wordpress.com/1129/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/bytebaker.wordpress.com/1129/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/bytebaker.wordpress.com/1129/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/bytebaker.wordpress.com/1129/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/bytebaker.wordpress.com/1129/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/bytebaker.wordpress.com/1129/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/bytebaker.wordpress.com/1129/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/bytebaker.wordpress.com/1129/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1129&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://bytebaker.com/2010/07/22/revamping-the-bytebaker-series/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fcafd7571cc4c82dd3e31c7e728eb2d9?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Basu</media:title>
		</media:content>

		<media:content url="http://bytebaker.files.wordpress.com/2009/03/python.jpg" medium="image">
			<media:title type="html">python</media:title>
		</media:content>
	</item>
		<item>
		<title>Inception and abstraction</title>
		<link>http://bytebaker.com/2010/07/20/inception-and-abstraction/</link>
		<comments>http://bytebaker.com/2010/07/20/inception-and-abstraction/#comments</comments>
		<pubDate>Tue, 20 Jul 2010 21:10:32 +0000</pubDate>
		<dc:creator>Shrutarshi Basu</dc:creator>
				<category><![CDATA[Education]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[closures]]></category>
		<category><![CDATA[functions]]></category>
		<category><![CDATA[inception]]></category>
		<category><![CDATA[object oriented programming]]></category>
		<category><![CDATA[recursion]]></category>

		<guid isPermaLink="false">http://bytebaker.com/?p=1113</guid>
		<description><![CDATA[I watched Inception with friends last Saturday. I really enjoyed it and thought it was really well made, though it&#8217;s certainly a complex movie which you need to pay attention to. Considering that most of the readers of The ByteBaker are computer savvy (and probably programmers) you&#8217;re going to like it (or hate it) very [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1113&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I watched <a href="http://www.imdb.com/title/tt1375666/">Inception</a> with friends last Saturday. I really enjoyed it and thought it was really well made, though it&#8217;s certainly a complex movie which you need to pay attention to. Considering that most of the readers of The ByteBaker are computer savvy (and probably programmers) you&#8217;re going to like it (or hate it) very much because it touches on some of our core concepts: recursion, closures and abstraction. In this way, it&#8217;s not all that much different from the Matrix &#8212; different premise and plotline but a very similar feel.</p>
<p>Without dropping any spoilers here&#8217;s what you need to know about the movie for the rest of the article: it&#8217;s about people who go into other people&#8217;s dreams in order to steal their secrets. Pretty simple, right? The kicker is that it&#8217;s possible to dream <em>inside </em>another dream leading to all sorts of interesting situations and plot twists. Ok, so that&#8217;s not quite recursion since that would mean that the subject would be dreaming the same dream inside the dream (confused yet?). Come to think of it the dreams of Inception are more like closures.</p>
<p>So what are closures? Wikipedia tells us that:</p>
<blockquote><p>In <a title="Computer science" href="http://en.wikipedia.org/wiki/Computer_science">computer science</a>, a <strong>closure</strong> is a <a title="First-class function" href="http://en.wikipedia.org/wiki/First-class_function">first-class function</a> with <a title="Free variables and bound variables" href="http://en.wikipedia.org/wiki/Free_variables_and_bound_variables">free variables</a> that are <a title="Name binding" href="http://en.wikipedia.org/wiki/Name_binding">bound</a> in the <a title="Lexical environment" href="http://en.wikipedia.org/wiki/Lexical_environment">lexical environment</a>.</p></blockquote>
<p>Perfectly understandable, right? No? Ok let&#8217;s translate. First and foremost, a closure is a function. But it&#8217;s not just any old run-of-the-mill function. A closure generally contains variables that are neither local variables nor arguments to that function. So what do those variables refer to? Their values come from <em>outside</em> the function, specifically the code block that surrounds the function. The wikipedia page on closures gives examples in a number of languages. Though closures aren&#8217;t necessarily a part of a standard curriculum they are extremely powerful constructs that can be used to implement a host of other programming language features (including control flow structures and object systems). Coming back to Inception, once you are inside a dream you can recall  the world outside (though the real world seems like a dream so everything&#8217;s a bit fuzzy). <a href="http://bytebaker.files.wordpress.com/2010/07/recursion.png"><img class="alignright size-full wp-image-1118" title="Recursion" src="http://bytebaker.files.wordpress.com/2010/07/recursion.png?w=360&#038;h=288" alt="" width="360" height="288" /></a></p>
<p>Closures in computer science (and dreams in Inception) are important because they are a prime example of abstraction. Functions are a powerful concept because they essentially let you create little worlds in which you can do stuff. You put something in a function and get something out. You don&#8217;t need to know or care about what&#8217;s going on inside the function (unless something goes wrong, but that&#8217;s a different matter entirely). Functions let you abstract away processes. Closures improve upon functions and let you abstract state. If you&#8217;re using a function that&#8217;s a closure, you don&#8217;t need to know about what it&#8217;s variables are bound to (except the ones you pass in) and you can&#8217;t see what data the closure can manipulate either.</p>
<p>By tucking away state, closures give us less to hold in our minds and make it easier to write code that&#8217;s clean and follows the Single Responsibility Principle (essentially, do one thing and do it well). Suppose you have a bunch of closures inside one larger function. Now magically you have sections of executable code that all operates on the same data and yet can do completely different things. They can also do all this without having to passing in a host of arguments every time (which reduces the chance for making mistakes). Whenever the closures need something, they just refer to their outer environment. Sound familiar? It should because I just described objects and methods. And that is the hallmark of a good abstraction &#8212; it lets you build up other abstractions on top.</p>
<p>Abstractions are in general a good thing. But unless you think through your abstractions, they can be bad. A leaky abstraction is one that doesn&#8217;t quite get it right. The underlying layers somehow &#8220;leak through&#8221; what should be the abstraction&#8217;s water tight boundaries. Joel Spolsky has a <a href="http://www.joelonsoftware.com/articles/LeakyAbstractions.html">very good article</a> on leaky abstraction that&#8217;s a must read if you want to learn more. And while we&#8217;re on the topic of abstraction &#8212; too much can be a bad thing. I wrote a Python program two summers ago to experiment with L-systems. Last summer I tried rewriting it such that everything in the system was the instance of some class. Everything was supposed to go through methods and abstraction boundaries. I never finished. This summer I toned it down a little and got a working version in about a week. Yes, this is classic second system effect, but it also shows that sometimes abstractions will just get in the way and force you to jump through hoops.</p>
<p>In conclusion: abstractions are good if used wisely. Closures are one such powerful abstraction. Dream safe.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/bytebaker.wordpress.com/1113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/bytebaker.wordpress.com/1113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/bytebaker.wordpress.com/1113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/bytebaker.wordpress.com/1113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/bytebaker.wordpress.com/1113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/bytebaker.wordpress.com/1113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/bytebaker.wordpress.com/1113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/bytebaker.wordpress.com/1113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/bytebaker.wordpress.com/1113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/bytebaker.wordpress.com/1113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/bytebaker.wordpress.com/1113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/bytebaker.wordpress.com/1113/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/bytebaker.wordpress.com/1113/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/bytebaker.wordpress.com/1113/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1113&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://bytebaker.com/2010/07/20/inception-and-abstraction/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fcafd7571cc4c82dd3e31c7e728eb2d9?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Basu</media:title>
		</media:content>

		<media:content url="http://bytebaker.files.wordpress.com/2010/07/recursion.png" medium="image">
			<media:title type="html">Recursion</media:title>
		</media:content>
	</item>
		<item>
		<title>Release schedules and version numbers</title>
		<link>http://bytebaker.com/2010/07/16/release-schedules-and-version-numbers/</link>
		<comments>http://bytebaker.com/2010/07/16/release-schedules-and-version-numbers/#comments</comments>
		<pubDate>Fri, 16 Jul 2010 19:06:52 +0000</pubDate>
		<dc:creator>Shrutarshi Basu</dc:creator>
				<category><![CDATA[Productivity]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[git]]></category>
		<category><![CDATA[google chrome]]></category>

		<guid isPermaLink="false">http://bytebaker.com/?p=1110</guid>
		<description><![CDATA[I just finished a major rewrite and overhaul of my long-term research project and pushed it out to other students who are working with me on it. In the process of the redo I rewrote large parts of it to be simpler code and added a few important features. I also cleaned up the code [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1110&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>I just finished a major rewrite and overhaul of my long-term research project and pushed it out to other students who are working with me on it. In the process of the redo I rewrote large parts of it to be simpler code and added a few important features. I also cleaned up the code organization (everything is neatly divided into directories instead being spread throughout the toplevel), added comments and rewrote the documentation to actually described what the program did and how to use it. But it wasn&#8217;t just a pure rewrite and refactoring. I added at least one important new feature, added a completely new user interaction mode and changed the code architecture to explicitly support multiple interfaces. But the thing is that even though I&#8217;ve &#8220;shipped&#8221; it, it&#8217;s still not quite done.</p>
<p>There are significant parts missing. The unit testing is very, very scant. There is almost no error handling. The previous version had a GUI which I need to port to the new API/architecture. I also want to write one more interaction mode as a proof of concept that it can support multiple, different modes. The documentation needs to be converted to HTML mode and there are some utility functions that would be helpful to have. In short, there&#8217;s a lot that needs to be done. So my question is, what version of my code is this?</p>
<p>I started a rewrite of this last  summer as well but never finished &#8212; a casualty classic second system effect. For a while I considered calling this version 3.0 counting the unfinished copy as 2.0. But I decided it was rather silly and so I&#8217;ve actually called it 2.0. Though it&#8217;s certainly a major major change from the last version, in some ways it&#8217;s still broken and unfinished. Is it a beta? Or a release candidate? I suppose that&#8217;s a better description. Except the additions that I want to make are more than moving it from a beta to a full release. The GUI would definitely be a point release.</p>
<p>In many ways the debate is purely academic and kinda pointless. As I&#8217;ve written before, <a href="http://bytebaker.com/2008/12/12/software-is-forever-beta/">software is always </a><a href="http://bytebaker.com/2008/12/12/software-is-forever-beta/">beta</a>. However, releasing major and minor &#8220;versions&#8221; of software is a popular activity. In some ways it&#8217;s helpful to the user. You can tell when something&#8217;s changed significantly and when you need to upgrade. In an age where you had to physically sell software, that was a good thing to know. However, the rise of web-based software has changed that to a large extent. If you&#8217;ve been using Gmail for a while, you&#8217;ll know that it has a history of small, regular atomic improvements over time. And it&#8217;s not just Gmail, it&#8217;s most of Google&#8217;s online services. Sometimes there are major facelifts (like Google Reader a few years ago) but by and large this gradual improvement works well. Google Chrome also uses this model. Chrome is officially past version 5 now. But thanks to its built in auto update mechanism you don&#8217;t need to care (and I suspect most people don&#8217;t). Rolling releases are clearly acceptable and may just be the way software updates are going to go in the future. Of course, if you&#8217;re charging for your code you&#8217;re going to have some sort of paywall, so no, manual software updates probably won&#8217;t go away forever.</p>
<p>Coming back to my original question, what version did I just release? 2.0? 2.0 beta 1? 1.9.5? Honestly I don&#8217;t really care. Part of my disinterest stems from the fact that Git makes branching and merging so easy. It&#8217;s hard to care about version numbers and releases when your code is in the hands of a system that makes it so easy to spin off feature branches and then merge them back in when they&#8217;re ready. If I worked in a fully Git based team I&#8217;d just have everyone running daily merges so that everyone just automatically got the new features. In that case I wouldn&#8217;t have waited to release. The big new feature would have been pushed a week ago, the reorganization and cleanup after that and then the documentation yesterday. I&#8217;d also be sending out the later updates and addition one at a time once they were done. Everyone else uses SVN, there might still be a way to do it.</p>
<p>In conclusion: rolling releases are awesome. Users don&#8217;t have to worry about manually updating and automagically get new features when they&#8217;re available. Developers using a good version control system can be up-to-date with everyone else&#8217;s code. This is especially important if you&#8217;re writing developer tools (which I am): the faster and easier you can get your updates to the people making the end product the faster the end product gets developed.</p>
<p>PS. If you&#8217;re wondering what exactly it is I&#8217;m making, more on that later. There&#8217;s a possibility of a source release after I talk to my professor about it.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/bytebaker.wordpress.com/1110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/bytebaker.wordpress.com/1110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/bytebaker.wordpress.com/1110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/bytebaker.wordpress.com/1110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/bytebaker.wordpress.com/1110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/bytebaker.wordpress.com/1110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/bytebaker.wordpress.com/1110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/bytebaker.wordpress.com/1110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/bytebaker.wordpress.com/1110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/bytebaker.wordpress.com/1110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/bytebaker.wordpress.com/1110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/bytebaker.wordpress.com/1110/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/bytebaker.wordpress.com/1110/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/bytebaker.wordpress.com/1110/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1110&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://bytebaker.com/2010/07/16/release-schedules-and-version-numbers/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fcafd7571cc4c82dd3e31c7e728eb2d9?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Basu</media:title>
		</media:content>
	</item>
		<item>
		<title>Nothing left to lose</title>
		<link>http://bytebaker.com/2010/07/13/nothing-left-to-lose/</link>
		<comments>http://bytebaker.com/2010/07/13/nothing-left-to-lose/#comments</comments>
		<pubDate>Wed, 14 Jul 2010 00:32:13 +0000</pubDate>
		<dc:creator>Shrutarshi Basu</dc:creator>
				<category><![CDATA[Internet]]></category>
		<category><![CDATA[News]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Apple]]></category>
		<category><![CDATA[Google]]></category>
		<category><![CDATA[Kin]]></category>
		<category><![CDATA[microsoft]]></category>

		<guid isPermaLink="false">http://bytebaker.com/?p=1106</guid>
		<description><![CDATA[Today&#8217;s been a productive day. Lot of code written, good conversation and a lot of reading done. I caught up with my backlog of stuff I had to read around the internet and even let myself carry on reading links. Out of everything I read, there are two things I read that I feel worth [...]<img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1106&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></description>
			<content:encoded><![CDATA[<p>Today&#8217;s been a productive day. Lot of code written, good conversation and a lot of reading done. I caught up with my backlog of stuff I had to read around the internet and even let myself carry on reading links. Out of everything I read, there are two things I read that I feel worth writing.</p>
<p>The first was <a href="http://minimsft.blogspot.com/2010/07/kin-fusing-kin-clusion-to-kin-and-fy11.html">about Microsoft and the recent Kin debacle</a>. It&#8217;s a good article with lots of remarks from people inside Microsoft and it&#8217;s definitely worth a read if you&#8217;re interested in technology or business at all. The article paints a pretty grim picture of where Microsoft is going. MS is definitely not my favorite technology company (and I&#8217;ve been Windows free for a while now) but it still hurts a little to see a once-gre﻿at company go so tragically wrong. As I was reading that article I kept thinking that Microsoft really needed a cold, hard reboot. A complete restructuring where they would identify their core strengths (Windows and Office), unify their various disparate projects (Mobile/Kin, all their various web efforts) and bring more developers onto their side (C#, F# and the rest of .NET). Is any of this going to happen? I don&#8217;t know. ﻿I ho﻿pe so, but my gut says no, sadly.</p>
<p>However, when I read <a href="http://blog.steinberg.org/?p=11">this next article</a> (about weak AI applied to cars and massive data sets) one line stuck out that pretty much summed up what I thought about Microsoft and its current situation. The line was this: It turns out that, innovation, like freedom, “is just another word for having nothing left to lose.” Very fitting, yes?</p>
<p>I think what everyone is feeling that Microsoft is simply far too big and unwieldy to make the drastic changes that are really necessary for it to stay in the game against the likes of Apple and Google. Restructuring a large company to fend off faster moving rivals is never an easy thing to do and it&#8217;s even harder when:</p>
<ol>
<li>You&#8217;re company is violently divided politically into jealous corporate fiefdoms</li>
<li>Everyone in the world seems to know about how bad it is</li>
</ol>
<p>The feeling that I think is prevalent is that even though Microsoft desperately needs to make an about turn in a lot of different areas, they&#8217;re not going to. Not yet, not unless more heads have rolled and not until they&#8217;ve lost a lot more, both in terms of interesting products and shareholder value. In other words, Microsoft will have to be forced into a situation where they have nothing left to lose before they start to really make the changes that they need to.</p>
<p>And that is sad. Sure, I&#8217;ve bashed Microsoft before and I&#8217;m certainly not a fan of Windows, but I too want them to get their act together and become a formidable software company again. I have good friends working at Microsoft who have had good experiences and I&#8217;ve heard good things about C# and .NET (language geek that I am). If nothing else, diversity is good and the more sources of interesting technology we have, the better. So I wish Microsoft the best of luck and really, really hope that the Kin (and Courier before it) are what finally kick Microsoft into action and push themselves to get back to the top of the game. Will that actually happen? We&#8217;ll see.</p>
<br />  <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gocomments/bytebaker.wordpress.com/1106/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/comments/bytebaker.wordpress.com/1106/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godelicious/bytebaker.wordpress.com/1106/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/delicious/bytebaker.wordpress.com/1106/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gofacebook/bytebaker.wordpress.com/1106/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/facebook/bytebaker.wordpress.com/1106/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gotwitter/bytebaker.wordpress.com/1106/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/twitter/bytebaker.wordpress.com/1106/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/gostumble/bytebaker.wordpress.com/1106/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/stumble/bytebaker.wordpress.com/1106/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/godigg/bytebaker.wordpress.com/1106/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/digg/bytebaker.wordpress.com/1106/" /></a> <a rel="nofollow" href="http://feeds.wordpress.com/1.0/goreddit/bytebaker.wordpress.com/1106/"><img alt="" border="0" src="http://feeds.wordpress.com/1.0/reddit/bytebaker.wordpress.com/1106/" /></a> <img alt="" border="0" src="http://stats.wordpress.com/b.gif?host=bytebaker.com&blog=8123270&post=1106&subd=bytebaker&ref=&feed=1" width="1" height="1" />]]></content:encoded>
			<wfw:commentRss>http://bytebaker.com/2010/07/13/nothing-left-to-lose/feed/</wfw:commentRss>
		<slash:comments>3</slash:comments>
	
		<media:content url="http://1.gravatar.com/avatar/fcafd7571cc4c82dd3e31c7e728eb2d9?s=96&#38;d=identicon&#38;r=G" medium="image">
			<media:title type="html">Basu</media:title>
		</media:content>
	</item>
	</channel>
</rss>