<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-8176680</id><updated>2011-12-02T13:37:48.656+05:30</updated><title type='text'>The Gladiator</title><subtitle type='html'>You want to see a Miracle. Then BE the Miracle. :-)</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>36</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-8176680.post-113355015633401872</id><published>2005-12-03T00:20:00.000+05:30</published><updated>2005-12-03T06:17:04.926+05:30</updated><title type='text'>Tendulkar Vs Others again</title><content type='html'>&lt;a href="http://content-usa.cricinfo.com/columns/content/story/228073.html"&gt;Read this article: Tendulkar against others in Run chases  &lt;/a&gt;&lt;br /&gt;&lt;br /&gt;For those who havent:: the stats are excluding vs zim,ban,and other non test playing nations. Only ODIs.&lt;br /&gt;&lt;br /&gt;Run chases &lt;240&gt;240.&lt;br /&gt;&lt;br /&gt;See where Tendulkar stands.&lt;br /&gt;&lt;br /&gt;A key extract:&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;In these 21 matches when the team has chased more than 240, Tendulkar has come up with some sterling performances - two of the most memorable ones were against arch-rivals Pakistan: in the 2003 World Cup at Centurion, Tendulkar blitzed 98 of the finest, in the process winning a key battle against Shoaib Akhtar; then, on the tour to Pakistan in 2004, Tendulkar kept India going virtually single-handedly when they were faced with a huge target of 330 at Rawalpindi, scoring a magnificent 141. &lt;span style="font-style: italic; font-weight: bold;"&gt;What's probably added to the perceptions against Tendulkar is the results of the matches when Tendulkar has got starts: he has topped fifty in six of those 21 matches, and India have gone on to lose five (the only victory came in the World Cup match against Pakistan).&lt;/span&gt;&lt;/li&gt; &lt;/ul&gt; Tendulkar's 50-plus scores chasing more than 240 since 2002   Score      Opposition      Match&lt;br /&gt;98     Pakistan     Centurion, 2003&lt;br /&gt;68     Australia     Mumbai, 2003-04&lt;br /&gt;89     Australia     Bangalore, 2003-04&lt;br /&gt;63     Australia     Melbourne, 2004-05&lt;br /&gt;141     Pakistan     Rawalpindi, 2003-04&lt;br /&gt;78     Pakistan     Colombo, 2004&lt;br /&gt;&lt;br /&gt;I still maintian my original stand.&lt;span style="font-weight: bold; font-style: italic;"&gt; No individual in a game like cricket is a match winner&lt;/span&gt;. Based on the maximum contributions you can attribute that title to that individual for that match. But then "man of the match" is a better title. Isnt it?&lt;br /&gt;&lt;br /&gt;But people on the team have to play their roles well. The team where maximum individuals contribute wins consitently. At times individuals will overshadow the team. But champion temas have great contributors. And there will be times when individuals will go into a rough patch, when others have to stretch themselves a bit more. Thats what is called 'resilience' of a good team. Does India have it now?Probably yes. But did it have earlier. Emphatically no.&lt;br /&gt;&lt;br /&gt;The problem was all Indians only believed and I think more so his critics that only he has the ability to win matches for India which is sad. So in a way the Tendulkar critcs love him more than his fans. AN amazing irony. Also shows that critics need to understand team games more.&lt;br /&gt;&lt;br /&gt;And looking at Tendulkar with the role to provide starts and solid ones, in the matches above he was a match winner but for his team mates not being upto the mark on those days. So there will be days when Tendulkar will be not upto the mark. So what?  look at the 6 times when he has contributed brilliantly but others around him have failed. We won only 1. Also look at the oppositon. And 4 of these have been played away. And 2 come on bouncy tracks of Centurion and Melbourne. Only match winners have the guts to play such knocks :-)&lt;br /&gt;&lt;br /&gt;Also look at his strike rate. And yes see Lara and Ponting in run chases. Especially Ponting. Shows why Australia is a champion team. And in ODIs I dont remember Lara playing a single significant knock to date. Also in test matches he is not that great. But test matches we will debate later.&lt;br /&gt;&lt;br /&gt;I still stick to the opinion that cricket is a team game and ppl have to play the roles given to them. You cant give the role of a quick start, anchor in the middle and finish the innings to Tendulkar.&lt;br /&gt;&lt;br /&gt;I think then its better of he plays alone if thats the case. Rest can go and rest(REAL REST i mean hehehe) in the hotel rooms.&lt;br /&gt;&lt;br /&gt;I am not against anyone voicing his opinion or disliking Tendulkar. Each has a right to his own opinion and to express it. But then be fair.&lt;br /&gt;&lt;br /&gt;Point is have same standards applied to all. If Tendulkar fails in few innings all tongues will start wagging. But why not for others?Only when SG put his foot in Chappell's mouth then the calls for his head started vociferously. Why not earlier?Where are the critics when Lara doesnt perform in ODI's (he has given up..hahaha)?And where were these critics when Yuvraj's only consistency was to fail consistently?&lt;br /&gt;&lt;br /&gt;My take::&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;&lt;span style="font-style: italic; font-weight: bold;"&gt;Great starters in ODIS:&lt;/span&gt; Tendulkar , Jayasuriya, Gilchrist. All start solidly and have many times played upto the 45th over. You cant expect these guys to anchor and finish. Not humanly possible. Once in a while yes but not always. And yes the statsn in run chases have also been shown . So Tendulkar is not bad as its made out to be ;-). Sehwag not yet. Because he cant survive for long. Thats OK i think for all Tendlya bashers . hahaha. Dhoni when he starts opening will quickly join the group. &lt;/li&gt; &lt;/ul&gt; &lt;ul&gt;   &lt;li&gt;&lt;span style="font-weight: bold; font-style: italic;"&gt;Great anchros in ODIs&lt;/span&gt;: Inzamam, Dravid, Kallis and Martyn. Inzamam is undoubtedly the best.   &lt;/li&gt; &lt;/ul&gt; &lt;ul&gt; &lt;/ul&gt; &lt;ul&gt;   &lt;li&gt;&lt;span style="font-weight: bold; font-style: italic;"&gt; Great finishers&lt;/span&gt;: Klusener, Yuvraj,S Waugh. Probably Waugh is the only one who figures in 2 and 3 both. And yes Dravid has the potential to be a Waugh (almost there) but then if he was perfect match winner he should have really played a solid knock at Calcutta. As Waugh had done at Edgbaston in WC 99 with Aus firmly with their backs to the wall. &lt;/li&gt; &lt;/ul&gt;And yes Tendlyas start to end knocks in Sharjah against Aus havent been seen. Please add up the pressure factor also. Against Aus away and 2 must win matches. Dhonis' 183 against SL comes to my mind but still its just a notch less due to pressure factor.&lt;br /&gt;&lt;br /&gt;And yes if Tendlya is as bad then I am awaiting for Chappell to fire and get fired. ;-)&lt;br /&gt;&lt;br /&gt;For a champion team, one needs to have a mix of solid starters, acnhors and finishers with a mix of youth and experience. Aus is that team and Ind now is close on their heels. Enjoy.&lt;br /&gt;&lt;br /&gt;PS:::None of this be taken personally.&lt;br /&gt;&lt;br /&gt;Please leave your comments on the blog post. And we can follow the trace. Cheers.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-113355015633401872?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/113355015633401872/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=113355015633401872&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/113355015633401872'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/113355015633401872'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/12/tendulkar-vs-others-again.html' title='Tendulkar Vs Others again'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-113276908831044259</id><published>2005-11-23T23:33:00.000+05:30</published><updated>2005-11-29T02:03:45.036+05:30</updated><title type='text'>Interesting facts about Nokia and mobile phones</title><content type='html'>1.  Imagine your mobile battery is very low, you are expecting an&lt;br /&gt;Important Call and you don't have a charger. Nokia instrument comes with&lt;br /&gt;reserve Battery. To activate, key is *3370# your mobile will restart with&lt;br /&gt;this Reserve and your instrument will show a 50% increase in battery. This&lt;br /&gt;Reserve will get charged when you charge your cell next time.&lt;br /&gt;&lt;br /&gt;2. The Emergency Number worldwide for Mobile is 112. If you findyourself out of coverage area of your mobile network and there is an&lt;br /&gt;emergency, dial 112 and the mobile will search any existing network to&lt;br /&gt;establish the emergency number for you.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-113276908831044259?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/113276908831044259/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=113276908831044259&amp;isPopup=true' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/113276908831044259'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/113276908831044259'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/11/interesting-facts-about-nokia-and.html' title='Interesting facts about Nokia and mobile phones'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-113019231602290000</id><published>2005-10-25T03:40:00.000+05:30</published><updated>2005-10-25T03:48:36.036+05:30</updated><title type='text'>World X I Selectors....Were you listening?</title><content type='html'>In the recently held ICC Super Series, World XI was thrashed, beaten to pulp by the aussies in both one day series and super six day test match which ended in 3 days :-) or were the ICC planning for 2 super test matches..ahahha&lt;br /&gt;&lt;br /&gt;So ICC thought..hey lets bring 11 world best players..and then they should just appear on the ground and success will be theirs..Aussies will be humbled on their homeground after being beaten fair and square (no debates here please) by English in the earlier concluded Ashes..&lt;br /&gt;&lt;br /&gt;But..wink wink..we get the opposite..The big giants..are brought to their knees...Knock knock..why..The Selectors missed the big factor..The "TEAM" factor..Can these 11 stars play as 11 close knit, well informed, aware of each other, trusting, communicating members of a well oiled team..The thing they must have looked for is can we bring 11 above average players from non Aussie teams, see how they can gel, how much time would that take and then pitted them against the Aussies...That would have surely been more brilliant than Eng Vs Aus 2005 or Ind vs Aus 2001 series...2 very famous closely and hard fought test series...&lt;br /&gt;&lt;br /&gt;So alls gone down the wind..ICC does best what they can now..they see no ICC super series...so it means you blame the players and everything else but your abiltity to pick the right players..ICC doesnt want to learn..I think...No wonder the game is being held togehter by a few wonderful unselfish players on each team...&lt;br /&gt;&lt;br /&gt;Lesson for us: The team's only goal is to succeed, not to have A star team which can figure out how to win and thats what &lt;a href="http://www.scottberkun.com/essays/essay47.htm"&gt;Scott says here in this wonderful essay...&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;h3&gt;The myth of all star teams&lt;/h3&gt;     All-star teams lose. While it’s an honor to be chosen to an all-star team,       it’s miserable to play on one. These teams are constructed without consideration       for how to bring people together. Whenever an all-star team plays a mediocre,       but intact team, they usually lose.&lt;br /&gt;Read this and apply to World X1 team and it looks like Scott saw the matches and then wrote the article..But then where ever teams are expected to win these rules laid down in the essay apply..&lt;br /&gt;------Scott Berkun&lt;br /&gt;&lt;br /&gt;Looks like Scott saw the matches and wrote the essay..But then this applies to all teams...Great essay..Must read..highly recommended..&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-113019231602290000?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/113019231602290000/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=113019231602290000&amp;isPopup=true' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/113019231602290000'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/113019231602290000'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/10/world-x-i-selectorswere-you-listening.html' title='World X I Selectors....Were you listening?'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-112977948635191928</id><published>2005-10-20T08:43:00.000+05:30</published><updated>2005-10-23T06:07:51.540+05:30</updated><title type='text'>I am Impressed. Mighty Impressed</title><content type='html'>On an earlier post I had mentioned that I will be comparing EzExpense java application by rewriting it in Ruby. But I thought let me start at a smaller scale and I went back to my numerology application.&lt;br /&gt;&lt;br /&gt;Let me explain the application domain:&lt;br /&gt;&lt;br /&gt;I meet a numerologist Janjay Sumani . He wants an application for the following. People come to him for advice on numbers. Given a person's name and birth date he computes some numbers and tells them what numbers they belong to, what are lucky, unlucky blah blah. Note by this I dont expect anyone to believe in numerology nor does the blogger.&lt;br /&gt;&lt;br /&gt;Back to business I ask him give me an example : He says lets start with u.&lt;br /&gt;&lt;br /&gt;Ur name: Deepak Manharlal Surti and Date of birth : 24 May 1977&lt;br /&gt;&lt;br /&gt;He says we have a letter-number chart which tells the numeric value of each letter. We subsittue that for each word in a name. So Deepak =&gt; 455812. Now we find sum of digits : 455812 = &gt; 25 =&gt; 7. Here he gives me a caveat: If the number is any of 11 , 22, 33, 44, 55, 66, 77, 88, 99 we dont reduce.&lt;br /&gt;&lt;br /&gt;So lets do the calcs for Deepak Manharlal Surti&lt;br /&gt;=&gt; 455812 415512313 36241&lt;br /&gt;=&gt;25 25 16&lt;br /&gt;=&gt;7 7 7&lt;br /&gt;=&gt;21&lt;br /&gt;&lt;br /&gt;So 21 is higher name number. Reduce 21 =&gt;3 gives me lower name number. Haa now I understand I say.&lt;br /&gt;&lt;br /&gt;Next we pick the birht date:&lt;br /&gt;24 May 1977&lt;br /&gt;=&gt; 24 5 1977&lt;br /&gt;=&gt; 6 5 24&lt;br /&gt;=&gt; 6 5 6&lt;br /&gt;=&gt; 17&lt;br /&gt;&lt;br /&gt;So 17 is my higher destiny number and 8 is my lower destiny number.&lt;br /&gt;&lt;br /&gt;And just take the day you were born. 24. So 24 =&gt; 6 are my higher and lower material numbers respectively.&lt;br /&gt;&lt;br /&gt;I start with app development using TDD (Test Driven Development) style and here's what I get:&lt;br /&gt;&lt;br /&gt;I had written that app in Java with a web interface and a domain model. The classes in the domain&lt;br /&gt;model were:&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;NumerologyCalculator.java (80 lines)--This was the central class. It calculated numbers.&lt;br /&gt;&lt;/li&gt;   &lt;li&gt;NameManipulator.java (41 lines) -- This was to split a name into individual parts (viz Deepak Surti is split into [Deepak, Surti])&lt;/li&gt;   &lt;li&gt;Letter.java(19 lines) -- A final class to hold letter values. A has value 1, D has value 4 etc in numerology. To look up these values.&lt;br /&gt;&lt;/li&gt;   &lt;li&gt;DateGenerator.java(28 lines) -- A class to generate dates given a string. Note I didnt use java's Date class it was too complicated for my app. I instead created a custom MyDate class which comes next. Here i just need mth, year, day.&lt;/li&gt;   &lt;li&gt;MyDate.java (31 lines) -- This had no responsibility. Its just a java bean.&lt;/li&gt;   &lt;li&gt;UserInfoBean.java (84 lines) -- This was just a bean to hold user info viz his name, date and numbers.&lt;/li&gt; &lt;/ul&gt; Now lets add up . We get 283 lines of domain model code. Just to calculate numbers for a person given his name and date.&lt;br /&gt;&lt;br /&gt;Further there was test code. Unit test which was 128 lines for the main TestNumerology.java. Here I tested only 6 birth dates and 3 names which I can say is not extensive coverage.&lt;br /&gt;There were other test classes for other domain model objects which we ignore.&lt;br /&gt;&lt;br /&gt;See all domain model code: Though its much better than procedural Java code that I have written in the past :-(( and thankfully have given up where I can, this code is still way 2 different from real business logic. How I wish my domain code and the business sat naturally with each other. That is if I could write code which read so much like the business. Anyways the code for u to see:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;package com.deepaksurti.numerology.calculate;&lt;br /&gt;&lt;br /&gt;import junit.framework.*;&lt;br /&gt;import java.util.*;&lt;br /&gt;&lt;br /&gt;import com.deepaksurti.numerology.calculate.BirthDate;&lt;br /&gt;import com.deepaksurti.numerology.calculate.NumerologyCalculator;&lt;br /&gt;&lt;br /&gt;/**&lt;br /&gt;* Created by IntelliJ IDEA.&lt;br /&gt;* User: Deepak Surti&lt;br /&gt;* Date: Dec 10, 2001&lt;br /&gt;* Time: 10:14:55 PM&lt;br /&gt;* To change this template use Options | File Templates.&lt;br /&gt;*/&lt;br /&gt;public class TestNumerology extends TestCase{&lt;br /&gt;NumerologyCalculator _calculator;&lt;br /&gt;private BirthDate  _birthDate1;&lt;br /&gt;private BirthDate _birthDate2;&lt;br /&gt;private BirthDate _birthDate3;&lt;br /&gt;private BirthDate _birthDate4;&lt;br /&gt;private BirthDate _birthDate5;&lt;br /&gt;private BirthDate _birthDate6;&lt;br /&gt;private String _name1;&lt;br /&gt;private String _name2;&lt;br /&gt;private String _name3;&lt;br /&gt;&lt;br /&gt;protected void setUp() {&lt;br /&gt;_calculator = new NumerologyCalculator();&lt;br /&gt;_birthDate1 = new BirthDate(24, 5, 1977);&lt;br /&gt;_birthDate2 = new BirthDate(14, 5, 1977);&lt;br /&gt;_birthDate3 = new BirthDate(4, 5, 1977);&lt;br /&gt;_birthDate4 = new BirthDate(24, 11, 1977);&lt;br /&gt;_birthDate5 = new BirthDate(24, 12, 1977);&lt;br /&gt;_birthDate6 = new BirthDate(28, 3, 1977);&lt;br /&gt;_name1 = new String("Deepak Manharlal Surti");&lt;br /&gt;_name2 = new String("Shilpa Pratap Shinde");&lt;br /&gt;_name3 = new String("Manhar Balubhai Surti");&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public void testMaterialNo() {&lt;br /&gt;int material_no;&lt;br /&gt;&lt;br /&gt;material_no = _calculator.calculateMaterialNo(_birthDate1);&lt;br /&gt;assertEquals(material_no, 6);&lt;br /&gt;&lt;br /&gt;material_no = _calculator.calculateMaterialNo(_birthDate2);&lt;br /&gt;assertEquals(material_no, 5);&lt;br /&gt;&lt;br /&gt;material_no = _calculator.calculateMaterialNo(_birthDate3);&lt;br /&gt;assertEquals(material_no, 4);&lt;br /&gt;&lt;br /&gt;material_no = _calculator.calculateMaterialNo(_birthDate6);&lt;br /&gt;assertEquals(material_no, 1);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public void testHigherMaterialNo() {&lt;br /&gt;int higherMaterialNo;&lt;br /&gt;&lt;br /&gt;higherMaterialNo = _calculator.calculateHigherMaterialNo(_birthDate1);&lt;br /&gt;assertEquals(higherMaterialNo, 24);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public void testDestinyNo(){&lt;br /&gt;int destiny_no;&lt;br /&gt;destiny_no = _calculator.calculateDestinyNo(_birthDate1);&lt;br /&gt;assertEquals(destiny_no, 8);&lt;br /&gt;&lt;br /&gt;destiny_no = _calculator.calculateDestinyNo(_birthDate4);&lt;br /&gt;assertEquals(destiny_no, 5);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public void testHigherDestinyNo() {&lt;br /&gt;int higherDestinyNo;&lt;br /&gt;&lt;br /&gt;higherDestinyNo = _calculator.calculateHigherDestinyNo(_birthDate1);&lt;br /&gt;assertEquals(higherDestinyNo, 17);&lt;br /&gt;&lt;br /&gt;higherDestinyNo = _calculator.calculateHigherDestinyNo(_birthDate4);&lt;br /&gt;assertEquals(higherDestinyNo, 23);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public void testMonthNo() {&lt;br /&gt;int month_no;&lt;br /&gt;&lt;br /&gt;month_no = _calculator.calculateMonthNo(_birthDate1);&lt;br /&gt;assertEquals(month_no, 5);&lt;br /&gt;&lt;br /&gt;month_no = _calculator.calculateMonthNo(_birthDate4);&lt;br /&gt;assertEquals(month_no, 11);&lt;br /&gt;&lt;br /&gt;month_no = _calculator.calculateMonthNo(_birthDate5);&lt;br /&gt;assertEquals(month_no, 3);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public void testYearNo() {&lt;br /&gt;int year_no;&lt;br /&gt;&lt;br /&gt;year_no = _calculator.calculateYearNo(_birthDate1);&lt;br /&gt;assertEquals(year_no, 6);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public void testNameNo() {&lt;br /&gt;&lt;br /&gt;int name_no;&lt;br /&gt;&lt;br /&gt;name_no = _calculator.calculateNameNo(_name1);&lt;br /&gt;assertEquals(name_no, 3);&lt;br /&gt;&lt;br /&gt;name_no = _calculator.calculateNameNo(_name2);&lt;br /&gt;assertEquals(name_no, 5);&lt;br /&gt;&lt;br /&gt;name_no = _calculator.calculateNameNo(_name3);&lt;br /&gt;assertEquals(name_no, 1);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public void testHigherNameNo() {&lt;br /&gt;int higherNameNo;&lt;br /&gt;&lt;br /&gt;higherNameNo = _calculator.calculateHigherNameNo(_name1);&lt;br /&gt;assertEquals(higherNameNo, 21);&lt;br /&gt;&lt;br /&gt;higherNameNo = _calculator.calculateHigherNameNo(_name2);&lt;br /&gt;assertEquals(higherNameNo, 14);&lt;br /&gt;&lt;br /&gt;higherNameNo = _calculator.calculateHigherNameNo(_name3);&lt;br /&gt;assertEquals(higherNameNo, 19);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;-------------------------------------------------------------------------&lt;br /&gt;&lt;br /&gt;package com.deepaksurti.numerology.calculate;&lt;br /&gt;&lt;br /&gt;import com.deepaksurti.numerology.calculate.BirthDate;&lt;br /&gt;&lt;br /&gt;import java.util.Collection;&lt;br /&gt;import java.util.Iterator;&lt;br /&gt;&lt;br /&gt;/**&lt;br /&gt;* Created by IntelliJ IDEA.&lt;br /&gt;* User: Deepak Surti&lt;br /&gt;* Date: Dec 22, 2001&lt;br /&gt;* Time: 9:34:16 AM&lt;br /&gt;* To change this template use Options | File Templates.&lt;br /&gt;*/&lt;br /&gt;public class DateGenerator {&lt;br /&gt;public static BirthDate generateBirthDate(String date) {&lt;br /&gt;Collection splitUpDates = NameManipulator.locateWordsInName(date);&lt;br /&gt;Iterator it = splitUpDates.iterator();&lt;br /&gt;int dates[] = new int[3];&lt;br /&gt;int index = 0;&lt;br /&gt;while(it.hasNext()) {&lt;br /&gt;   String next = (String)it.next();&lt;br /&gt;   if(next.equals("")) dates[index++] = 0;&lt;br /&gt;   else&lt;br /&gt;   dates[index++] = (new Integer(next)).intValue();&lt;br /&gt;}&lt;br /&gt;return new BirthDate(dates[0], dates[1], dates[2]);&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;---------------------------------------------------------------------------&lt;br /&gt;&lt;br /&gt;package com.deepaksurti.numerology.calculate;&lt;br /&gt;&lt;br /&gt;import java.util.HashMap;&lt;br /&gt;&lt;br /&gt;/**&lt;br /&gt;* Created by IntelliJ IDEA.&lt;br /&gt;* User: Deepak Surti&lt;br /&gt;* Date: Dec 20, 2001&lt;br /&gt;* Time: 12:57:55 PM&lt;br /&gt;* To change this template use Options | File Templates.&lt;br /&gt;*/&lt;br /&gt;public final class Letter {&lt;br /&gt;private static int _letterValues[] = new int[]&lt;br /&gt;{1, 2, 3, 4, 5, 8, 3, 5, 1, 1, 2, 3, 4, 5, 7, 8, 1, 2, 3, 4, 6, 6, 6, 6, 1, 7};&lt;br /&gt;&lt;br /&gt;public static int lookUpLetterValue(char letter) {&lt;br /&gt;return _letterValues[letter - 65];&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;---------------------------------------------------------------------------&lt;br /&gt;&lt;br /&gt;package com.deepaksurti.numerology.calculate;&lt;br /&gt;&lt;br /&gt;import java.util.Collection;&lt;br /&gt;import java.util.Iterator;&lt;br /&gt;import java.util.ArrayList;&lt;br /&gt;&lt;br /&gt;/**&lt;br /&gt;* Created by IntelliJ IDEA.&lt;br /&gt;* User: Deepak Surti&lt;br /&gt;* Date: Dec 20, 2001&lt;br /&gt;* Time: 8:37:32 PM&lt;br /&gt;* To change this template use Options | File Templates.&lt;br /&gt;*/&lt;br /&gt;public class NameManipulator {&lt;br /&gt;public static Collection locateWordsInName(String name) {&lt;br /&gt;Collection spaces = locateSpacesInName(name);&lt;br /&gt;Iterator it = spaces.iterator();&lt;br /&gt;Collection wordsInName = new ArrayList();&lt;br /&gt;int beginIndex = 0, endIndex;&lt;br /&gt;while(it.hasNext()) {&lt;br /&gt;   endIndex = ((Integer)it.next()).intValue();&lt;br /&gt;   wordsInName.add(name.substring(beginIndex, endIndex));&lt;br /&gt;   beginIndex = endIndex + 1;&lt;br /&gt;}&lt;br /&gt;wordsInName.add(name.substring(beginIndex, name.length()));&lt;br /&gt;return wordsInName;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public static Collection locateSpacesInName(String name) {&lt;br /&gt;name = name.toUpperCase();&lt;br /&gt;char letter;&lt;br /&gt;ArrayList spaces = new ArrayList();&lt;br /&gt;for (int index = 0; index &lt; letter =" name.charAt(index);"&gt;= 65 &amp;&amp;amp;amp;amp;amp;amp;amp;amp;amp;amp; letter &lt;=90) || (letter &gt;= 48 &amp;&amp;amp; letter &lt;= 57)){ continue; } else spaces.add(new Integer(index)); } return spaces; } } --------------------------------------------------------------------------- &lt;/code&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;The simple web interface looked like this :&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://photos1.blogger.com/blogger/7340/541/1600/numerology1.jpg"&gt;&lt;img style="margin: 0px auto 10px; display: block; text-align: center; cursor: pointer;" src="http://photos1.blogger.com/blogger/7340/541/400/numerology.jpg" alt="Click to enlarge" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Now I sit down with Ruby. And what I have. 1 tc_numerology.rb for test cases which is worth 93 lines but you know what it covers 68 assertions which is fantastic coverage. My complete test case is worth assertions.&lt;br /&gt;&lt;br /&gt;And all my business aka domain logic is in just 1 numerology.rb file which is only 46 lines of code. So compare 46 to 283. Plus I was amazingly comfortable while writing ruby code. I felt like a child when I used to play with building blocks for hours and hours. Ruby is so much intutive.&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;And here comes the Ruby code: Compare this with java version above and you will see the difference for yourself:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;&lt;br /&gt;module Numerology&lt;br /&gt;&lt;br /&gt;Values = { "a" =&gt; "1", "b" =&gt; "2", "c" =&gt; "3", "d" =&gt; "4", "e" =&gt; "5", "f" =&gt; "8", "g" =&gt; "3",&lt;br /&gt; "h" =&gt; "5", "i" =&gt; "1", "j" =&gt; "1", "k" =&gt; "2", "l" =&gt; "3", "m" =&gt; "4", "n" =&gt; "5",&lt;br /&gt; "o" =&gt; "7", "p" =&gt; "8", "q" =&gt; "1", "r" =&gt; "2", "s" =&gt; "3", "t" =&gt; "4", "u" =&gt; "6",&lt;br /&gt; "v" =&gt; "6", "w" =&gt; "6", "x" =&gt; "5", "y" =&gt; "1", "z" =&gt; "7"}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;Power_numbers = [11,22,33,44,55,66,77,88,99]&lt;br /&gt;&lt;br /&gt;class Calculator&lt;br /&gt;def name_destiny_number(name)&lt;br /&gt;names = name.split(/[^A-Za-z]/)&lt;br /&gt;names.delete("")&lt;br /&gt;names.each {|name| name.downcase!.gsub!(/[a-z]/) {|ch| Numerology::Values[ch]}}&lt;br /&gt;numbers = names.collect {|name| name.to_i}&lt;br /&gt;numbers = numbers.collect {|num| num = Numerology::number(num)}&lt;br /&gt;numbers.inject(0) {|x, sum| sum + x}&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;def name_material_number(name)&lt;br /&gt;Numerology::number(name_destiny_number(name))&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;def date_destiny_number(date)&lt;br /&gt;Numerology::number(date.day) + Numerology::number(date.month) + Numerology::number(date.year)&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;def date_material_number(date)&lt;br /&gt;Numerology::number(date.day)&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;def Numerology.sum(x)&lt;br /&gt;x / 10 &gt; 0 ? (x % 10) + sum(x / 10) : x % 10&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;def Numerology.number(num)&lt;br /&gt;while num &gt; 9 and !Numerology::Power_numbers.include? num&lt;br /&gt;num = sum(num)&lt;br /&gt;end&lt;br /&gt;num&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;end&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;And my ruby test case looks like this:&lt;br /&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;require 'test/unit'&lt;br /&gt;&lt;br /&gt;$:.unshift File.join(File.dirname(__FILE__), "..", "lib")&lt;br /&gt;&lt;br /&gt;require 'numerology'&lt;br /&gt;&lt;br /&gt;require 'test/unit'&lt;br /&gt;&lt;br /&gt;$:.unshift File.join(File.dirname(__FILE__), "..", "lib")&lt;br /&gt;&lt;br /&gt;require 'numerology'&lt;br /&gt;&lt;br /&gt;class TestNumerology &lt; calculator =" Numerology::Calculator.new"&gt;&lt;br /&gt;&lt;br /&gt;Now lets revisit the main code and see how it compares it with Janjay does::&lt;br /&gt;&lt;code&gt;&lt;br /&gt;class Calculator&lt;br /&gt;def name_destiny_number(name)&lt;br /&gt;names = name.split(/[^A-Za-z]/)&lt;br /&gt;names.delete("")&lt;br /&gt;names.each {|name| name.downcase!.gsub!(/[a-z]/) {|ch| Numerology::Values[ch]}}&lt;br /&gt;numbers = names.collect {|name| name.to_i}&lt;br /&gt;numbers = numbers.collect {|num| num = Numerology::number(num)}&lt;br /&gt;numbers.inject(0) {|x, sum| sum + x}&lt;br /&gt;end&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;&lt;span style="font-weight: bold; color: rgb(255, 0, 0);"&gt;See first line splits a name into its individual words (what Janjay Sumani does)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-weight: bold; color: rgb(255, 0, 0);"&gt;Next it removes any additonal spaces user may have entered (Janjay doesnt care)&lt;/span&gt;&lt;br /&gt;&lt;span style="font-weight: bold; color: rgb(255, 0, 0);"&gt;Next we replace each character with its value from hash map&lt;/span&gt;&lt;br /&gt;&lt;span style="font-weight: bold; color: rgb(255, 0, 0);"&gt;next we just convert strings like "455812" to a number 455812 &lt;/span&gt;&lt;code style="font-weight: bold; color: rgb(255, 0, 0);"&gt;(Janjay does these 2 steps looking into his chart)&lt;/code&gt;&lt;br /&gt;&lt;code style="font-weight: bold; color: rgb(255, 0, 0);"&gt;Next for each number like we saw in example right at the top we get reduced number. The line &lt;/code&gt;&lt;code&gt;&lt;span style="font-weight: bold; color: rgb(255, 0, 0);"&gt;   numbers = numbers.collect {|num| num = Numerology::number(num)} does the magic.&lt;/span&gt;&lt;br /&gt;&lt;span style="font-weight: bold; color: rgb(255, 0, 0);"&gt;And then i find the sum using inject method on arrays.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold; color: rgb(102, 102, 204);"&gt;&lt;span style="color: rgb(255, 0, 0);"&gt;See didnt it feel like Janjay was at work and not some stupid obsucre compiler that makes you a better break dancer than Michaeal Jackson? I bet..&lt;/span&gt;.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;The great ideas whcih differentiate Ruby viz blocks have been used here. When you wanna learn focus a lot on its library, built in classes, modules, how to package using gems , and more importantly blocks and closures. When I move to write Tk interface I can explain closures better. Blocks originated with iterators but thats not their only usage.&lt;br /&gt;&lt;br /&gt;I cant explain Ruby here. I have just started but it has got me hooked. I now wnat to write 3 interfaces for this : one using Rails (thats coming next mth), one using Tk and one using AJax. And we will compare these 3, time it takes blah blah to java.&lt;br /&gt;I am already putting my money on Ruby.&lt;br /&gt;&lt;br /&gt;Nice pointer to start Ruby &lt;a href="http://www.loudthinking.com/arc/000199.html"&gt;this&lt;/a&gt;. Have Andy and Dave's book &lt;a href="http://www.amazon.com/exec/obidos/tg/detail/-/0974514055/104-4038833-1853529?v=glance"&gt;'Programming Ruby'&lt;/a&gt; by your side. If you are really keen to make a difference you will learn Ruby. Its a great journey.&lt;br /&gt;&lt;br /&gt;And yes I will test this language out more thoroughly with EzExpense a home finance calculator which has some crazy logic, which finance app doesnt have. That will be FUN.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-112977948635191928?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/112977948635191928/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=112977948635191928&amp;isPopup=true' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112977948635191928'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112977948635191928'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/10/i-am-impressed-mighty-impressed.html' title='I am Impressed. Mighty Impressed'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-112974344628643190</id><published>2005-10-19T23:05:00.000+05:30</published><updated>2005-10-20T00:07:39.426+05:30</updated><title type='text'>Thats what being called Humble</title><content type='html'>&lt;a href="http://us.rediff.com/movies/2005/oct/19mad.htm"&gt;An extract from a news on Rediff Madhavan will host this new game show&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;"All I can say is, it has no relevance or connection to Kaun Banega Crorepati [the Indianised version of Who Wants To Become A Millionaire]. It's a different format. And we will not pitch it against KBC. Our show will be telecast on weekdays. &lt;span style="font-weight: bold;"&gt;Who on earth would dare to take on Mr [Amitabh] Bachchan&lt;/span&gt;?"&lt;br /&gt;&lt;br /&gt;Now i like this..i think this show may be successful because they are intelligent enough to not take on AB. Well done Madhavan . You are way common sensical beyond those morons who did try to take on the giant AB and returned with miserable results..:-)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-112974344628643190?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/112974344628643190/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=112974344628643190&amp;isPopup=true' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112974344628643190'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112974344628643190'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/10/thats-what-being-called-humble.html' title='Thats what being called Humble'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-112630965517227010</id><published>2005-09-10T05:09:00.000+05:30</published><updated>2005-09-10T05:19:20.606+05:30</updated><title type='text'>My Ruby Journey Has Started</title><content type='html'>Yes eventually I started on my journey to learn Ruby. Not just learn but with the hopes&lt;br /&gt;that someday I will make a very fulfilling career out of it.&lt;br /&gt;&lt;br /&gt;Dreams apart, I just went on to &lt;a href="http://www.ruby-lang.org/"&gt;ruby-lang&lt;/a&gt;, downloaded the win installer, and started&lt;br /&gt;with this link &lt;a href="http://www.rubyist.net/%7Eslagell/ruby/"&gt;Ruby Quick Tour&lt;/a&gt; to get going on the basics. I prefer to get the wider picture.&lt;br /&gt;&lt;br /&gt;Next I have just ordered the &lt;a href="http://www.pragmaticprogrammer.com/titles/ruby/index.html"&gt;Programming Ruby&lt;/a&gt; book from Bordrers and I will use it&lt;br /&gt;to rewrite my EzExpense application in Ruby. Gives me a real example to compare Java&lt;br /&gt;and Ruby (though it may end up like comparing apples and oranges..really:-). Also I dont find&lt;br /&gt;just reading a book or even solving examples given in a book the best way to learn. I feel happier and more satisifed if I can apply the learnings to write somethign significant. Makes me more confident for the real world later on.&lt;br /&gt;&lt;br /&gt;I will also put my comparisions of EzExpense code in Ruby vis a vis Java. Where ruby helped me, where java (though from what I have read and known, the latter should be rare!!!). And I will also know writing this application if over an application Ruby is still as simulating and fun as I found it while going through the Quick tour above. So watch out for the comparisions.&lt;br /&gt;&lt;br /&gt;Finally I will make EzExpense easy to use using &lt;a href="http://www.rubyonrails.org/"&gt;Ruby on Rails&lt;/a&gt; framework. I as of now give&lt;br /&gt;myself time till year end effectively 3 mths , in Dec 05 I may be on vacation in Ind..so I have&lt;br /&gt;started my innings..let me see how it goes..:-)..&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-112630965517227010?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/112630965517227010/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=112630965517227010&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112630965517227010'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112630965517227010'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/09/my-ruby-journey-has-started.html' title='My Ruby Journey Has Started'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-112430459141820386</id><published>2005-08-18T00:18:00.000+05:30</published><updated>2005-08-18T00:22:13.526+05:30</updated><title type='text'>Its not 2 late to learn</title><content type='html'>Its not too late to learn. &lt;a href="http://www.sdtimes.com/article/opinion-20050815-02.html"&gt;Jim Shore on FBI Virtual Case File (VCF) project disaster&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-112430459141820386?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/112430459141820386/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=112430459141820386&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112430459141820386'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112430459141820386'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/08/its-not-2-late-to-learn.html' title='Its not 2 late to learn'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-112423592716980051</id><published>2005-08-17T05:11:00.000+05:30</published><updated>2005-08-17T05:15:27.176+05:30</updated><title type='text'>Consensus or Instinct</title><content type='html'>My moment of reckoning came in vastly different circumstances as I lay prone with a Hannibal Lecter mask protecting a nose with multiple fractures in a Colombo hospital bed next to Jason Gillespie, who had a shattered leg bone and a fractured wrist. It was during a reflective look back at my captaincy up to that point that I realised if I didn't make it back to captain Australia again, I had sold myself short as I'd captained by consensus and not by my instincts. In my sorry state I vowed to always back my gut feeling and to never hesitate in the future. -- Steve Waugh&lt;br /&gt;&lt;br /&gt;This maps directly to the book Blink I am reading. So much are we taugh to collect data, think&lt;br /&gt;a lot before doing something. There will however be roles in life, times when we have to go purely by instincts. Now if you are not trained or habitual in doing that it may turn out to be so good.&lt;br /&gt;Read Blink a great book to train yourself to when believe in ur snap judgements and when not.&lt;br /&gt;&lt;br /&gt;So also for agile. If I go by consensus I am sure the answer will not be to agilers liking. But if go by my instincts I think Agile will surely make its mark in various forms. But then Blink has taught me "Blink judgements are nothing but a collated results of your experiences. At times processing is correct and at times not. The key to unlock is when it correct and when not" :-)&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-112423592716980051?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/112423592716980051/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=112423592716980051&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112423592716980051'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112423592716980051'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/08/consensus-or-instinct.html' title='Consensus or Instinct'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-112423404347798943</id><published>2005-08-17T04:43:00.000+05:30</published><updated>2005-08-17T04:44:03.483+05:30</updated><title type='text'>Data Crunching - I cant forget these lines</title><content type='html'>For want of a nail the shoe was lost.&lt;br /&gt;For want of a shoe the horse was lost.&lt;br /&gt;For want of a horse the rider was lost.&lt;br /&gt;For want of a rider the battle was lost.&lt;br /&gt;For want of a battle the kingdom was lost.&lt;br /&gt;And all for the want of a horseshoe nail.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-112423404347798943?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/112423404347798943/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=112423404347798943&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112423404347798943'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112423404347798943'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/08/data-crunching-i-cant-forget-these.html' title='Data Crunching - I cant forget these lines'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-112413745794440687</id><published>2005-08-16T01:52:00.000+05:30</published><updated>2005-08-16T01:54:17.950+05:30</updated><title type='text'>Keep It Simple and Sloppy - KISS</title><content type='html'>My friend Vipul passed me this link.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.adambosworth.net/archives/000031.html"&gt;Keep it Simple and Sloppy - Adam Bosworth&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-112413745794440687?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/112413745794440687/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=112413745794440687&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112413745794440687'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112413745794440687'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/08/keep-it-simple-and-sloppy-kiss.html' title='Keep It Simple and Sloppy - KISS'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-112339704983523980</id><published>2005-08-07T12:14:00.000+05:30</published><updated>2005-08-07T12:37:46.700+05:30</updated><title type='text'>Every cloud has a SILVER lining</title><content type='html'>These are  the bombay kids after the  rains that caused havoc. &lt;a href="http://picasa.google.com/" target="ext"&gt;&lt;img src="http://photos1.blogger.com/pbp.gif" alt="Posted by Picasa" style="border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;" align="middle" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic; font-weight: bold;"&gt;Lesson to learn:&lt;/span&gt; Only if each one could retain the child in him/her and the child like&lt;br /&gt;enthusiasm , the WOLRD would be so much a better place :-)&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;A few optimistic lines of a song that I can recall for these rains:(Hindi)&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Dekh Na mere sar se Aasman Ud gaya hain&lt;br /&gt;Dekh Na Aasman ke sire Khul gaye Hain Zameen Se&lt;br /&gt;&lt;br /&gt;Dekh Na kya huan hain Yeh zameen beh rahi hain&lt;br /&gt;Dekh Na paaniyon mein zameen ghul rahi hain kahin se&lt;br /&gt;&lt;br /&gt;Aasman baadlon par karvate le raha hain&lt;br /&gt;Dekh Na aasman hi barasne lage na zameen pe&lt;br /&gt;&lt;br /&gt;Yeh zameen paaniyon pe dubkiyan le rahi hain&lt;br /&gt;Dekh Na Uthke pairon pe chalne lage na kahin pe&lt;br /&gt;&lt;br /&gt;Dekh Na mere sar se Aasman Ud gaya hain&lt;br /&gt; Dekh Na Aasman ke sire Khul gaye Hain Zameen Se&lt;br /&gt;&lt;br /&gt; Dekh Na kya huan hain Yeh zameen beh rahi hain&lt;br /&gt; Dekh Na paaniyon mein zameen ghul rahi hain kahin se&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href="http://photos1.blogger.com/img/190/2106/1024/bombay_rain.jpg"&gt;&lt;img style="border: 2px solid rgb(0, 0, 0); margin: 2px;" src="http://photos1.blogger.com/img/190/2106/400/bombay_rain.jpg" border="0" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-112339704983523980?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/112339704983523980/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=112339704983523980&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112339704983523980'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112339704983523980'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/08/every-cloud-has-silver-lining.html' title='Every cloud has a SILVER lining'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-112293739256644756</id><published>2005-08-02T04:25:00.000+05:30</published><updated>2005-08-02T04:33:12.580+05:30</updated><title type='text'>My First Tryst with Digital Asset Management</title><content type='html'>Just in the past week I have been offered an opportunity to make myself more acquainted with&lt;br /&gt;Digital Asset Management. I have been working on java j2ee projects for a studio , on assignment/s for the company that I work for.&lt;br /&gt;&lt;br /&gt;Now this was a great opportunity because it helps me go into the business side of things also&lt;br /&gt;which is as important as the techie side. Why? Read "&lt;span style="font-size:100%;"&gt;Beyond Software Architecture: Creating and Sustaining Winning Solutions by Luke Hoffman".&lt;br /&gt;&lt;br /&gt;So the key question was how do i start? Thats the most difficult part always. Then I thought the best way to get an overview woudl be to assume that I am gonna buy a DAM Solution :-) . What would I do? Thats the best way to learn things. Try buying a camera or a laptop or a car and you learn so many things.&lt;br /&gt;&lt;br /&gt;Then I looked up the net and found an interesting article from which I can summarize the following:&lt;br /&gt;&lt;br /&gt;Digital Asset Managment has 3 key meanings: Something that is in electronic form is owned by me , I own lots of it and now I m trying to manage it.  Go furtther you see this electronic form is nothing but media aka content. So I started to find the meaning of media and ....heres what i get ....&lt;br /&gt;&lt;br /&gt;What is media? Media is something that holds content.It can be of different forms:&lt;br /&gt;artwork, logos, audio files, video files, even PPTs , text docs, emails probably.&lt;br /&gt;&lt;br /&gt;Any such media if converted to binary (digital) form makes it digital media. A whole&lt;br /&gt;set of digital media that an organization owns becomes its asset.&lt;br /&gt;&lt;br /&gt;Studies show that lots of productive time is spent in managing these assets. Typically&lt;br /&gt;searching for it, moving it to other teams (clients/suppliers).&lt;br /&gt;&lt;br /&gt;A DAM solution then is one which provides you better management of assets such that&lt;br /&gt;the productivity loss is minimized. It can provide many benefits such as efficent look up,&lt;br /&gt;availability on demand, automated workflow, better collaborative environment etc.&lt;br /&gt;&lt;br /&gt;Based on the objective of a DAM Solution one can classify it into desktop solutions,&lt;br /&gt;process oriented, merchant centric solutions etc.&lt;br /&gt;&lt;br /&gt;Based on architecture, DAM Solutions can be classified into media catalogs and asset&lt;br /&gt;repositories.&lt;br /&gt;&lt;br /&gt;You can either buy an off the shelf DAM solution, build one yourself if your business&lt;br /&gt;has such unique needs or with expertise in complex system integration use best of the&lt;br /&gt;breeed.&lt;br /&gt;&lt;br /&gt;Add to the above 3, the needs of your users, weed out the inefficiences in the current&lt;br /&gt;workflow and then try to identify the DAM solution.&lt;br /&gt;&lt;br /&gt;Now Look closely at your archiving needs. Analyze them in detail. This will be a key&lt;br /&gt;factor which is often overlooked.&lt;br /&gt;&lt;br /&gt;After all this,you look at your budget and you may just find the right DAM solution!&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-112293739256644756?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/112293739256644756/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=112293739256644756&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112293739256644756'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/112293739256644756'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/08/my-first-tryst-with-digital-asset.html' title='My First Tryst with Digital Asset Management'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-111860931037925167</id><published>2005-06-13T02:07:00.000+05:30</published><updated>2005-06-13T02:54:09.793+05:30</updated><title type='text'>Expense Calculator - Session 6</title><content type='html'>Till session 5, we implemented all 6 requirements. Time to take a look at the code keeping in mind the observations of the last session.&lt;br /&gt;&lt;br /&gt;First up I add more test coverage for other scenarios. Everythign works fine.&lt;br /&gt;&lt;br /&gt;But i had pointed out about making parellel class heirarchies of expense sheet and expense statement. I try doing it but when i realize the Factory Method signatures would be different I revert back to old desing. I prefer factory method only when method signatures are same and if different then its not 'so difficult' to make a guess about redundnant parameters. In my case the method signature of factory method becomes too long and confusing.&lt;br /&gt;&lt;br /&gt;Further I have kept Expense related classes package private. They wont be published to the outer world. So ensuring the right usage of two printStatement methods is possible. Thus no Introduce Polymorphic creation with factory method is used. :-). A case where refactoring doesnt make sense.&lt;br /&gt;&lt;br /&gt;Next I see my ExpenseSheet Test case and the test methods which test statement generation.The questoin that begs to be asked here is what should I create a Party as: Payer or Receiver. This question popped up only after adding more test scenarios. It becomes evident that Payer or Receiver is not 'really' a Party Type, but a role played a Party. So Party bhavdeep may be a payer in one transaction and receiver in another. Another advantage of using good test coverage. I refactor to form a Role heirarchy which is used by Party. I update my test cases. Now they look more sensible. My test methods have a common feel: Create parties, set up their roles, add transaction and test 'whatever aspect' you want to.&lt;br /&gt;&lt;br /&gt;Also I see that when I create a transaction I must process it. That is I need not call process. I make that method private , update my test cases and I call process in transaction constructor!Also in my test cases I did away with facade, dao classes. I will add these classes and packages only when required. In my test case I supply the Party with the list of transactions that it needs.&lt;br /&gt;&lt;br /&gt;Finally my Domain and Test Class Diagrams look like this:&lt;br /&gt;&lt;br /&gt;Domain:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.hello.com/" target="ext"&gt;&lt;img src="http://photos1.blogger.com/pbh.gif" alt="Posted by Hello" style="border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;" align="middle" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://photos1.blogger.com/img/190/2106/1024/DomainClassDiagram7.jpg"&gt;&lt;img style="border: 2px solid rgb(0, 0, 0); margin: 2px;" src="http://photos1.blogger.com/img/190/2106/480/DomainClassDiagram6.jpg" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Test:&lt;br /&gt;&lt;br /&gt;&lt;a href='http://www.hello.com/' target='ext'&gt;&lt;img src='http://photos1.blogger.com/pbh.gif' alt='Posted by Hello' border='0' style='border:0px;padding:0px;background:transparent;' align='absmiddle'&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href='http://photos1.blogger.com/img/190/2106/1024/TestClassDiagram1.jpg'&gt;&lt;img border='0' style='border:2px solid #000000; margin:2px' src='http://photos1.blogger.com/img/190/2106/480/TestClassDiagram1.jpg'&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Lessons Learnt:&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;I need to practice Refactorings a lot. I am still not natural at it.&lt;br /&gt; &lt;/li&gt;   &lt;li&gt;After that is done, come and add automated functional test cases for this project. I will use &lt;a href="http://fit.c2.com/"&gt;FIT&lt;/a&gt;&lt;br /&gt; &lt;/li&gt;   &lt;li&gt;Then attached UI and persistence and publish this desktop app.&lt;br /&gt; &lt;/li&gt;   &lt;li&gt;Then Claps. :-)&lt;br /&gt; &lt;/li&gt; &lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-111860931037925167?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/111860931037925167/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=111860931037925167&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111860931037925167'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111860931037925167'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/06/expense-calculator-session-6.html' title='Expense Calculator - Session 6'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-111846091758874411</id><published>2005-06-11T08:50:00.000+05:30</published><updated>2005-06-11T09:17:35.710+05:30</updated><title type='text'>Expense Calculator - Session 5</title><content type='html'>Now having implemented 4 requirements I come on to the next one:&lt;br /&gt;&lt;br /&gt;Requirement 5: Generate an expense statement for  a payer for a date range.&lt;br /&gt;&lt;br /&gt;Say for bhavdeep for 1 Apr to 30 Apr 2005 genrate an expense statement should look like this:&lt;br /&gt;&lt;br /&gt;Bhavdeep&lt;br /&gt;1 Apr 2005 to 30 Apr 2005&lt;br /&gt;&lt;br /&gt;Bhavdeep receive from Surender 13 USD&lt;br /&gt;Bhavdeep receive from Deepak 5 USD&lt;br /&gt;&lt;br /&gt;2 Apr 2005 Albertsons Deepak 12 USD&lt;br /&gt;7 Apr 2005CostCo Surender 5 USD&lt;br /&gt;16 Apr 2005 Burger King Deepak -7USD&lt;br /&gt;28 Apr 2005 Panda Express Surender 8 USD&lt;br /&gt;&lt;br /&gt;Thus we see a header with name, date range for statement, summary, and details.&lt;br /&gt;&lt;br /&gt;I write a unit test, it fails, then i go on to implement it and it passes. Same old style by now.&lt;br /&gt;But while implementing I am not able to come up with the right interface. I maintain a party message : getExpenseSheet(list transactions) and on expense sheet i supply party and date range as attributes to genrate statement. Is this the right way?Somehow I think not. I would like a party interface to which i can ask..getStatemetn(DateRange range). But then for that Pary would need to somehow get to the db and get list of transactions. So pary now talks to DB interafaces (not that i have any by now). But it would right. I dont like this coupling.&lt;br /&gt;&lt;br /&gt;I stop. I rethink.I see what the user of this domain package would be comfortable with. UI and domain intermediate layer would speak to domain layer. Now this layer would also access facades that can let it speak to db layer. So I think..Party or for that matter any domain object should just have responsibilities. It must not know about the external world of db, ui et al.&lt;br /&gt;&lt;br /&gt;So I come up with facades package. Primarily TransactionFacade that accepts a TransactionDao and gets me the list of transactiosn for date range. in my junit test case which i now re-write i use stubtransctiondao (not mock) and it returns me some canned transaction data. Good enough.&lt;br /&gt;&lt;br /&gt;Now my test flow looks like this:&lt;br /&gt;facade gets me list of trasnactions.&lt;br /&gt;i ask party to get expensestatmetn for this set of trasnactions.&lt;br /&gt;&lt;br /&gt;Simple this is . way better than my ugly looking test. also Party doesnt know where it got thsi set from (and rightly so). Now i look at expense sheet which does the bulk of printing. and its go t ugly. I see all this printing business requires a set of summary lines. I rightly move this code into an Extraced ExpenseStatement class. Now code looks cleaner.&lt;br /&gt;&lt;br /&gt;Now i move on to my next requirement : Expense statement for a transaction.&lt;br /&gt;&lt;br /&gt;Hmm.simple it looks. But when i see the structure of transaction expense statement i see it would have no details. Just trx name, date, payer, receivers and summary lines.&lt;br /&gt;&lt;br /&gt;Now i look at expense statemnt class. I see a herirachy. one for party and other for transaction. I first refactor expensestatement into expensestatemetna and its child partystatement class.&lt;br /&gt;Then i add the transcationstatement functionality.&lt;br /&gt;&lt;br /&gt;Also my party interface looks like this: getExpenseStatemetn(DateRange, List trasnactons). You may ask why both?&lt;br /&gt;&lt;br /&gt;First it lets me keep Party independent of calls to another layer such as persistence layer. Next daterange is required when printing the statement. AS of now this is good enough. Aslo that way i dont expose classes such as ExpenseStatement, ExpesneLine to the world outside domain package because they must not know about it. Lesser you expose better for your neighbors !!!!&lt;br /&gt;&lt;br /&gt;Finally my class diagram looks like this:&lt;br /&gt;&lt;br /&gt;A few observations on this class diagram:&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;   &lt;li&gt;Party Expense Statement and Transaction Expense Statement are bit more coupled. Time to look up the GoF catalog probably :-). But for now lets wait.&lt;br /&gt;  &lt;/li&gt;   &lt;li&gt;I can also probably have expensesheet heirarchy but that may lead to parellel class heirarchies. I need to evaluate.&lt;/li&gt;   &lt;li&gt;I need to do check my test coverage and make it more solid. Thats surely my next task.&lt;/li&gt;   &lt;li&gt;Also as of now I have the facility to handle transactions where payer has a share in expenses and doesnt have a share. When I think about those situations where part of expesnes are shared and part are not I realize the same classes do the trick. Basically I need to come up with a stable transction definition:&lt;/li&gt; &lt;/ol&gt; Transaction : is where there is only payer and there is only one amt. So a trx where total amt is 60$ but 40$ are shared equally but remaining 20$ are not is actually made up of 2 transactions: (assuming one payer of course): 40$ trx and 20$ trx. That gives me relief. At times simple thoughts do the trick .&lt;br /&gt;&lt;br /&gt;My domain vocab looks like this;&lt;br /&gt;&lt;br /&gt;Party: participates in transaction as payer or receiver&lt;br /&gt;Transaction: has one party (payer), one amt and one or more receivers.&lt;br /&gt;Distribution: Transaction amt is shared equally including payer (Equitable with Payer) or shared equally without the payer (Equitable without Payer)&lt;br /&gt;&lt;br /&gt;So the above and money, daterange classes are what my domain package exposes to the outer world and thats fine enough. Always give a great thought to what you must keep public, private, friendly et al. Its important. Start by being stingy and then become moderate if reqd. Because other way is almost impossible always especially when your clients start going out of your control boundaries.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.hello.com/" target="ext"&gt;&lt;img src="http://photos1.blogger.com/pbh.gif" alt="Posted by Hello" style="border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;" align="middle" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://photos1.blogger.com/img/190/2106/1024/DomainClassDiagram6.jpg"&gt;&lt;img style="border: 2px solid rgb(0, 0, 0); margin: 2px;" src="http://photos1.blogger.com/img/190/2106/480/DomainClassDiagram5.jpg" border="0" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-111846091758874411?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/111846091758874411/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=111846091758874411&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111846091758874411'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111846091758874411'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/06/expense-calculator-session-5.html' title='Expense Calculator - Session 5'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-111803291566963707</id><published>2005-06-06T10:02:00.000+05:30</published><updated>2005-06-11T08:49:58.880+05:30</updated><title type='text'>Expense Calculator - Session 4</title><content type='html'>In session 1, we implemented requirements 1 and 2. And sessions 2, 3 we spent time simplifying the design. At this stage we are now good enough to move on to implementing the next requirement.&lt;br /&gt;&lt;br /&gt;Requirement 3: Generate an expense sheet for a payer for a list of transactions for a date range.&lt;br /&gt;&lt;br /&gt;Steps:&lt;br /&gt;Wriet junit test case. While writing the test case I realize I have not added a date to transactoins. :-). So wear refactoirng hat and add date attribute to transaction.&lt;br /&gt;&lt;br /&gt;Next is handling date range. For me I have a Transaction class with date attribute. I guess that eventually the interface will boil down to a list of transactions. My query should fetch me the valid transactions. So i see something like party.getexpesesheet(transactions) as the interface.&lt;br /&gt;&lt;br /&gt;I complete test case, it fails. then i implement it and it passes.&lt;br /&gt;&lt;br /&gt;I have done the test for a payer. I do it for a receiver. IT also passes (claps) at first attempt.&lt;br /&gt;&lt;br /&gt;I am keeping my unit tests very simple. My automated functional tests which will load a real long list of transactions and generate expense sheet will really test this functionally out. But at class levels thses tests suffice. Thats what I think now but this can change later on ;-)&lt;br /&gt;&lt;br /&gt;Now I have added one more junit test case. I have 2 test cases. I scan the two and refactor them to form a heirarchy. This session really went smooth and fast. So thats what our rythm should be: write test case, fail, pass, refactor to simplify design, next req, test case, fail pass, refactor and so on.&lt;br /&gt;&lt;br /&gt;At the end I just try to review my classes. And I see something. EquitableDistribution and NonEQuitableDistribution. The latter (or both) class names are misleading. Why? I said earlier non equitable = where payer doesnt have a share in expenses. So the prefix non applies to 'payer doesnt'. But read nonequitable and it means not divided equally. Misleading ha. I come up with right names. EquitableWithParty and EquitableWithoutParty. I do the rename refactoring.:-). I also see something coming up: PartlyEquitableWithParty ... ;-) probably. But when it comes I will handle it.&lt;br /&gt;&lt;br /&gt;Next I move on to implement requirement 4: Generate an expense sheet for a receiver. This is pretty straight forward.&lt;br /&gt;&lt;br /&gt;A rythm has surely developed :-)&lt;br /&gt;&lt;br /&gt;The updated class diagram for domain and test sources look like this:&lt;br /&gt;&lt;br /&gt;Domain class diagram:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.hello.com/" target="ext"&gt;&lt;img src="http://photos1.blogger.com/pbh.gif" alt="Posted by Hello" style="border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;" align="middle" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://photos1.blogger.com/img/190/2106/1024/DomainClassDiagram5.jpg"&gt;&lt;img style="border: 2px solid rgb(0, 0, 0); margin: 2px;" src="http://photos1.blogger.com/img/190/2106/480/DomainClassDiagram4.jpg" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;Test class diagram:&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.hello.com/" target="ext"&gt;&lt;img src="http://photos1.blogger.com/pbh.gif" alt="Posted by Hello" style="border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;" align="middle" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://photos1.blogger.com/img/190/2106/1024/TestClassDiagram.jpg"&gt;&lt;img style="border: 2px solid rgb(0, 0, 0); margin: 2px;" src="http://photos1.blogger.com/img/190/2106/480/TestClassDiagram.jpg" border="0" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-111803291566963707?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/111803291566963707/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=111803291566963707&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111803291566963707'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111803291566963707'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/06/expense-calculator-session-4.html' title='Expense Calculator - Session 4'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-111794955700306030</id><published>2005-06-05T10:49:00.000+05:30</published><updated>2005-06-06T10:45:04.903+05:30</updated><title type='text'>Expense Calculator - Session 3</title><content type='html'>The tools I am using are:&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;Intellij Idea 4.5.3&lt;/li&gt;   &lt;li&gt;CVS for source control *its a local repository on my laptop&lt;/li&gt;   &lt;li&gt;Argo UML for class diagrams. I just used visual paradigm for session 1 but argo is what i m more comfortable with.&lt;br /&gt;&lt;/li&gt; &lt;/ul&gt;&lt;br /&gt;Till now the implementation looks good enough and more importantly simple. Now when I look at the expense sheet generated for the transaction it looks somehting like this for req 1: (&lt;a href="http://deepaksurti.blogspot.com/2005/06/expense-calculator-session-1.html"&gt;see session 1&lt;/a&gt;)&lt;br /&gt;&lt;br /&gt;bhavdeep 10 usd, deepak -5 usd, surender -5usd. Are these expense lines correct.yes but are they going to help me in my next req: that is generating an expense sheet for a party. say for bhavdeep across n transactions.&lt;br /&gt;&lt;br /&gt;just trying to add transaction expense sheets for reqs 1 and 2 I see a glaring hole: expense line doesnt say whome the money comes from or goes to. to implement that i see bhavdeep 10usd and deepak, surender -5usd are credit and debit lines respectively. Hmm..i see an expense line heirarchy. So i add these classes. *design hat.&lt;br /&gt;&lt;br /&gt;But while implementing i see that for credit lines there are multiple receivers who pay the amt. so for bhavdeep 10 usd, deepak and surender pay 5 usd each. essentially this is complicating matters. i think composite might come to rescue. but i always am wary of straight away jumping to patterns. they are complex beasts and u have to pay a price for using them. i try using compoiste and i see the design getting only complex. so i wait and do a relook.&lt;br /&gt;&lt;br /&gt;I relook at the expense sheet basically credit line. and after some scratching it strikes me:&lt;br /&gt;credit line 10usd is nothing but 2 credit lines of 5 usd. so my redone expense sheet now looks:&lt;br /&gt;bhavdeep 5 usd from deepak, bhavdeep 5 usd from surender, deepak 5usd to bhavdeep, surender 5 usd to bhavdeep. this clears up things. first every credit line has a debit line and vice versa. bidirectional association. also as of now my thinking is helped by having all 4 though in realiyt only 2 exist..both debit lines or credit lines. but then i can always wear my refactoring hat and remove them if reqd.&lt;br /&gt;&lt;br /&gt;i wear my refactoring hat/desing hat alternately and bring code into shape which looks now has simplifed transaction , payer classes and added an expense line heirarchy.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://deepaksurti.blogspot.com/2005/06/expense-calculator-session-4.html"&gt;Session 4&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;the class diagram looks like this: &lt;a href="http://photos1.blogger.com/img/190/2106/1024/DomainClassDiagram2.jpg"&gt;compare with session 2 class diagram&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.hello.com/" target="ext"&gt;&lt;img src="http://photos1.blogger.com/pbh.gif" alt="Posted by Hello" style="border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;" align="middle" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://photos1.blogger.com/img/190/2106/1024/DomainClassDiagram3.jpg"&gt;&lt;img style="border: 2px solid rgb(0, 0, 0); margin: 2px;" src="http://photos1.blogger.com/img/190/2106/480/DomainClassDiagram2.jpg" border="0" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-111794955700306030?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/111794955700306030/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=111794955700306030&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111794955700306030'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111794955700306030'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/06/expense-calculator-session-3.html' title='Expense Calculator - Session 3'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-111790614143964385</id><published>2005-06-04T22:53:00.000+05:30</published><updated>2005-06-05T11:25:57.030+05:30</updated><title type='text'>Expense Calculator - Session 2</title><content type='html'>At the end of session 1, I had mentioned that Transaction class is a place where we can use State pattern. The two scenarios we saw deal with an equitable (payer shares the expenses) and non-equitable (payer doesnt share the expenses).&lt;br /&gt;&lt;br /&gt;Analyze further and you can see that this characteristic about transactions is characterisitc of Party Heirarchy. Even party heirarchy is a bit confusing. Now if I create Distribution heirarchy and attach it to Transaction , then isParticipant method becomes redundant on Party heirarchy.&lt;br /&gt;&lt;br /&gt;That in turn lets me do away with ParticipantPayer and NonParticipantPayer. Because that is now controlled by Distribution heirarchy. So I end up with Party and Receiver. Then I trun Party Heirarchy into Payer and Receiver which makes it a lot simpler.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://deepaksurti.blogspot.com/2005/06/expense-calculator-session-3.html"&gt;Session 3&lt;/a&gt;&lt;br /&gt;&lt;br /&gt;See the class diagram below and compare it with &lt;a href="http://photos1.blogger.com/img/190/2106/1024/DomainClassDiagram1.jpg"&gt;the class diagram on session 1&lt;/a&gt;. This shows that its 'difficult' to come up with simple solutions but with agile techniques you can ;-)&lt;br /&gt;&lt;br /&gt;&lt;a href="http://www.hello.com/" target="ext"&gt;&lt;img src="http://photos1.blogger.com/pbh.gif" alt="Posted by Hello" style="border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;" align="middle" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://photos1.blogger.com/img/190/2106/1024/DomainClassDiagram2.jpg"&gt;&lt;img style="border: 2px solid rgb(0, 0, 0); margin: 2px;" src="http://photos1.blogger.com/img/190/2106/480/DomainClassDiagram1.jpg" border="0" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-111790614143964385?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/111790614143964385/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=111790614143964385&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111790614143964385'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111790614143964385'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/06/expense-calculator-session-2.html' title='Expense Calculator - Session 2'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-111786559446302175</id><published>2005-06-04T11:31:00.000+05:30</published><updated>2005-06-04T23:01:34.336+05:30</updated><title type='text'>Expense Calculator - Session 1</title><content type='html'>My first session.&lt;br /&gt;&lt;br /&gt;The following was achieved:&lt;br /&gt;&lt;ol&gt;   &lt;li&gt;Set up of intellij idea&lt;/li&gt;   &lt;li&gt;Requriements 1 and 2&lt;/li&gt; &lt;/ol&gt; Requirement 1: We bhavdeep, deepak, surender go to albertsons. Buy worth 15$ (we r stingy). bhavdeep pays. the expense amt is shared equally among 3.&lt;br /&gt;&lt;br /&gt;Steps: Write junit test case, it fails. Write code so test passes.&lt;br /&gt;&lt;br /&gt;Classes: Transaction, ExpenseSheet, ExpenseLine, Money, Party.&lt;br /&gt;&lt;br /&gt;Observations:&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;process method in Transaction generates Expense sheet. Has if statements to find out if Party is payer / receiver and then calculate. Smell of Party heirarchy&lt;/li&gt;   &lt;li&gt;other classes have relatively no behavior.&lt;/li&gt;   &lt;li&gt;decision: for this requirement its good enuf but when moving to other requirements i will have to wear my refacotring hat before implemetnation&lt;/li&gt; &lt;/ul&gt; Requirement 2: Same as requirement 1. Except bhavdeep has no share in the expenses. He only paid for it. divided equally between deepak and surender.&lt;br /&gt;&lt;br /&gt;Steps: Write junit test method, it fails, then write code to make it pass&lt;br /&gt;&lt;br /&gt;Classes: Transaction, ExpenseSheet, ExpenseLine, Money, Party, NonParticipantPayer-&gt;Party, Receiver-&gt;Party&lt;br /&gt;&lt;br /&gt;Observations:&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;Refactored Transaction , Party classes to distribute behavior of ExpenseSheet generation&lt;/li&gt;   &lt;li&gt;Heirarchy of Party created. Expense lines generation delegated to Party without conditional processing (claps)&lt;/li&gt;   &lt;li&gt;Transactions for above 2 requirements are equitable and non equitable. But they can change at run time. So I need to use State pattern. Havent done the refactoring. But its necessary though as of now only getEqualParts method has conditional processing. Thus this forms my next refactoring before I move on for the next requirement implementation&lt;/li&gt;   &lt;li&gt;Add more behavior into money class. Something like 5USd 3 times is 15USD should be done by money class. will make Party expense cacls simpler&lt;/li&gt; &lt;/ul&gt;&lt;a href="http://deepaksurti.blogspot.com/2005/06/expense-calculator-session-2.html"&gt;Session 2&lt;/a&gt;&lt;br /&gt;&lt;br /&gt; Current Class Diagram is [Click on the picture to see enlarged]:&lt;a href="http://www.hello.com/" target="ext"&gt;&lt;img src="http://photos1.blogger.com/pbh.gif" alt="Posted by Hello" style="border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;" align="middle" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://photos1.blogger.com/img/190/2106/1024/DomainClassDiagram1.jpg"&gt;&lt;img style="border: 1px solid rgb(0, 0, 0); margin: 2px;" src="http://photos1.blogger.com/img/190/2106/480/DomainClassDiagram.jpg" border="0" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-111786559446302175?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/111786559446302175/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=111786559446302175&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111786559446302175'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111786559446302175'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/06/expense-calculator-session-1.html' title='Expense Calculator - Session 1'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-111784242516928612</id><published>2005-06-04T05:13:00.000+05:30</published><updated>2005-06-04T11:50:53.856+05:30</updated><title type='text'>Expense Calculator Started</title><content type='html'>I have started working on a new self application . I call it Expense Calculator. My intention&lt;br /&gt;is to practice agile techniques: refactoring, unit testing, functional testing, automated builds to be precise.&lt;br /&gt;&lt;br /&gt;&lt;u&gt;About the app to be written:&lt;/u&gt;&lt;br /&gt;Whenever a few ppl stay togehter there are bound to be shared expenses. This calculator will let you enter your expenses and generate expense sheets detaling the expenses and amount you must pay / receive from others.&lt;br /&gt;&lt;br /&gt;&lt;u&gt;About the experiences while writing the app:&lt;/u&gt;&lt;br /&gt;I will put my experiences of writing the application in different posts and name them in this format: Expense Calculator Session X. Mainly I will put up a the targets I meet in each session and how the application evolves. Will elucidate them with class diagrams.&lt;br /&gt;&lt;br /&gt;I hope this helps not only me but others. At significant intervals, I will also release the code developed.&lt;br /&gt;&lt;br /&gt;&lt;a href="http://deepaksurti.blogspot.com/2005/06/expense-calculator-session-1.html"&gt;See : Expense Calculator - Session 1&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-111784242516928612?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/111784242516928612/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=111784242516928612&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111784242516928612'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111784242516928612'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/06/expense-calculator-started.html' title='Expense Calculator Started'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-111628916855517325</id><published>2005-05-17T05:13:00.000+05:30</published><updated>2005-08-17T05:19:50.270+05:30</updated><title type='text'>Hibernate Mappings &amp; Encapsulated Collections</title><content type='html'>&lt;a href="http://martinfowler.com/bliki/EncapsulatedCollection.html"&gt;Collections must be encapsulated.&lt;/a&gt; Also I am using Hibernate as the persistence solution. I have a uni-directional many to many relationship between Parent and Child. My java code looks like this:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;Parent {&lt;br /&gt;String name;&lt;br /&gt;Set children = new HashSet();&lt;br /&gt;&lt;br /&gt;public void getChildren() {&lt;br /&gt;return Collections.unmodifiableCollection(children);&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;private void setChildren(Set children) {&lt;br /&gt;this.children = children;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public void addChild(Child obj) {&lt;br /&gt;///.....&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public void removeChild(Child obj) {&lt;br /&gt;///....&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;Child {&lt;br /&gt;String name;&lt;br /&gt;//......&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;Now I have hibernate mapping like this:&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;For parent:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;set name="children" table="ParentChildren"&lt;br /&gt;key column="parent_child_id"&lt;br /&gt;many-to-many column="child_id" class="Child"&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Hibernate code:&lt;/span&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;session.createCriteria(Parent.class).list()&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;When I execute above code something funny happens:All join table records are deleted and re-inserted.&lt;br /&gt;&lt;br /&gt;The problem after digging through HIbernate documentation was this:&lt;br /&gt;&lt;br /&gt;You must return exactly the same collection that Hibernate sets else it will try to synchronize it with database. As such it deleted and inserted as I was returnign a read only collection, which was different from what I got from hibernate.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-style: italic; color: rgb(255, 0, 0);"&gt;Now if I pass a collection thats same I end up violating encapsulation.&lt;br /&gt;&lt;br /&gt;&lt;/span&gt;To my set I added inverse="true" attribute&lt;br /&gt;&lt;br /&gt;set name="children" inverse="true"&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;But this is an incorrect solution that works!.&lt;/span&gt; If you look up the definiton of inverse it means:&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;   &lt;li&gt;Inverse signifies a bi-direction association&lt;/li&gt;   &lt;li&gt;Inverse = true says that this end is not responsible for association maintenance.&lt;/li&gt; &lt;/ol&gt;&lt;br /&gt;As such inverse = true stopped the inserts/deletes. But then mine was a uni-direcitional relationship and this was wrong. Because as of now I am only reading the records its fine. But for manipulating children, inverse=true wont work. Becasue whatever I do with child collection wont be persisted to the db.&lt;br /&gt;&lt;br /&gt;&lt;span style="color: rgb(51, 102, 255); font-style: italic;"&gt;The challenge was thus to achieve both: encapsulation of collection and proper usage of hibernate.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;The solution looks like this:&lt;/span&gt;&lt;br /&gt;&lt;code&gt;&lt;br /&gt;Parent {&lt;br /&gt;private Set getChildren() {&lt;br /&gt;return this.children; //same as what hibernate sets..make it private&lt;br /&gt;}&lt;br /&gt;public Iterator children() {&lt;br /&gt;return this.children.iterator();&lt;br /&gt;&lt;span style="font-weight: bold; font-style: italic;"&gt;//now clients cant modify the collection without invokding add/remove methods&lt;/span&gt;&lt;br /&gt;}&lt;br /&gt;}&lt;/code&gt;&lt;br /&gt;&lt;br /&gt;Also the mapping remains the same as originally..viz without the inverese attribute because this is unidirectional association. Also semantically this is correct because now children manipulation will be persisted to the database.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Solution summary:&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;   &lt;li&gt;Make your get set methods on a collection private&lt;/li&gt;   &lt;li&gt;Add a method that returns an iterator to your collection&lt;/li&gt;   &lt;li&gt;Have add/remove encapsulation mehtods on your collection&lt;/li&gt;   &lt;li&gt;Look up hibernate docs to specify your mappings based upon if its unidirectional/bidirecitonal association.&lt;/li&gt;   &lt;li&gt;Remeber that cascade and inverse are orthogonal concepts.&lt;/li&gt; &lt;/ol&gt;&lt;br /&gt;The following links will make it all clear:&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;&lt;a href="http://martinfowler.com/bliki/EncapsulatedCollection.html"&gt;Refactoring - Encapsulated Collection&lt;/a&gt;&lt;br /&gt;&lt;/li&gt;   &lt;li&gt;&lt;a href="http://www.hibernate.org/155.html"&gt;Hibernate Explanation of inverse&lt;/a&gt;&lt;br /&gt;&lt;/li&gt;   &lt;li&gt;&lt;a href="http://www.hibernate.org/hib_docs/v3/reference/en/html/collections.html"&gt;Hibernate Persistent Collections Doc&lt;/a&gt;&lt;br /&gt;&lt;/li&gt;   &lt;li&gt;&lt;a href="http://www.hibernate.org/hib_docs/v3/reference/en/html/associations.html"&gt;Hibernate Association Mapping Doc&lt;/a&gt;&lt;br /&gt;&lt;/li&gt; &lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-111628916855517325?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/111628916855517325/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=111628916855517325&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111628916855517325'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111628916855517325'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/05/hibernate-mappings-encapsulated.html' title='Hibernate Mappings &amp; Encapsulated Collections'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-111613243574595789</id><published>2005-05-15T10:17:00.000+05:30</published><updated>2005-05-16T05:39:33.073+05:30</updated><title type='text'>My Desk</title><content type='html'>When its so tidy..chances are I may not be at work :-)) &lt;a href="http://www.hello.com/" target="ext"&gt;&lt;img src="http://photos1.blogger.com/pbh.gif" alt="Posted by Hello" style="border: 0px none ; padding: 0px; background: transparent none repeat scroll 0% 50%; -moz-background-clip: initial; -moz-background-origin: initial; -moz-background-inline-policy: initial;" align="middle" border="0" /&gt;&lt;/a&gt;&lt;br /&gt;&lt;a href="http://photos1.blogger.com/img/190/2106/50/DSC001582.jpg"&gt;&lt;img style="border: 1px solid rgb(0, 0, 0); margin: 2px;" src="http://photos1.blogger.com/img/190/2106/320/DSC00158.jpg" border="0" /&gt;&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-111613243574595789?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/111613243574595789/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=111613243574595789&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111613243574595789'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111613243574595789'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/05/my-desk_111613243574595789.html' title='My Desk'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-111575938849467439</id><published>2005-05-11T02:28:00.000+05:30</published><updated>2005-05-20T04:09:21.583+05:30</updated><title type='text'>Using Agile Practices</title><content type='html'>The past 3 yrs or so I have learnt a lot of lessons, most of which are "how to write better software". ...&lt;br /&gt;&lt;br /&gt;The challenge in front of me is to, at every given opportunity (with a change of perception I realize these are infinite) use agile practices.&lt;br /&gt;&lt;br /&gt;Why do I want to use agile practices?&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Most importantly using agile practices makes my life less stressful and work infinte fun :-)&lt;br /&gt;&lt;/li&gt; &lt;/ul&gt;&lt;br /&gt;On the whole I have decided to do this:&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;Use automated testing to whatever extent possible&lt;/li&gt;   &lt;li&gt;Use fully automated builds&lt;br /&gt;&lt;/li&gt;   &lt;li&gt;Tests should be of different types: unit, functional, peformance to say the least&lt;/li&gt;      &lt;li&gt;Refactor (but only after giving it a thought)&lt;br /&gt;&lt;/li&gt; &lt;/ul&gt; Let me see how much I succeed.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-111575938849467439?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/111575938849467439/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=111575938849467439&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111575938849467439'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111575938849467439'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/05/using-agile-practices.html' title='Using Agile Practices'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-111177883745222362</id><published>2005-03-26T00:47:00.000+05:30</published><updated>2005-05-20T04:10:43.396+05:30</updated><title type='text'>Automated Tests are Great</title><content type='html'>I was asked to write this utility to convert a graph of objects of type 'X' into type 'Y'. The difference between X and Y is that X objects sit in a layer whereas Y travel all over the network.&lt;br /&gt;&lt;br /&gt;I was already handed out some partly written code. I was happy because I am training myself to be an agile practitioner and reading, working on someone else's code should be easy for me. The hitch here was the part functionality wasnt complete and it wasnt backed up by any tests.&lt;br /&gt;&lt;br /&gt;I first wrote the part functionality. Then I wrote a junit test to verify it. THen i added few more test methods which made this part functioality a solid one. Next I moved to write the other test cases/methods and completing the whole utility. The utility used Reflection API. THe key to usage of this utility was people would have to genreate X and Y objects and have not irritating get/set methods to do the conversion.&lt;br /&gt;&lt;br /&gt;The user of this utility reported me one bug. Immediately I recreated that in junit and went on to fix it. And it was real quick.&lt;br /&gt;&lt;br /&gt;Now If you ask me how otherwise without junit I would have handled this surprisingly I dont know. Through some irrelevant uncomfortable system outs and lots of doubt, I believe.&lt;br /&gt;&lt;br /&gt;Hats off to Agile.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-111177883745222362?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/111177883745222362/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=111177883745222362&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111177883745222362'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/111177883745222362'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/03/automated-tests-are-great.html' title='Automated Tests are Great'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-110998313408036223</id><published>2005-03-05T05:12:00.000+05:30</published><updated>2005-05-20T04:11:13.376+05:30</updated><title type='text'>Changing Mindset</title><content type='html'>In an earlier post I had pointed out use of TDD and Refactoring to write the domain logic for poll measurements.&lt;br /&gt;&lt;br /&gt;2 Key activities still were to be done:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;Persist this data onto database.&lt;/li&gt;&lt;li&gt;Create views to play with this data.&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;You may have guessed I believe in working demos. Not html prototypes. I want to see in code that I can do it atleast in 1 way what I or you claim to be possible.&lt;/p&gt;&lt;p&gt;So I started off with the view. The user would enter the montly data and check up with the measurements (quarterly etc). When satisfied he would want to persist the data. But I like to take baby steps. Hence I decide let me get the calculation on a view out of the way.&lt;/p&gt;&lt;p&gt;I now moved to bea workshop to do this. I have liked its struts framework. I designed a jsp. THe jsp would invoke a calculateMeasurement action on this web app controller. The action would load the domain objects from the form and invoke appropriate domain methods and inform the view. The view would update it with the measures. The thing I like about struts framework provided by bea is the ease of use in dropping actions and invoking views without making my hands dirty.&lt;/p&gt;&lt;p&gt;This to my surprise worked fine. Because my domain logic was pretty much in place. Now I moved to handle persistence. I saw my db structure and domain structure have pretty much 1-1 relationship. SO active record could be a choice. Somehow I feel active record makes my objects bloated. I tend to shy away from it. I just used a db control a db facade. I wrote the insert logic on this control. Next I created a controller action to handle inserts. It would just pass on to the db control required data. Also the choice of db was pointbase. :-). Spend only 5$ when you need to spend 5$. A 100$ would be stupid aint it? oracle = 100$ pointbase = 5$.&lt;/p&gt;&lt;p&gt;Similary I crated update action. For handling the object insert/update state, I didnt use a state pattern. I would use that if I had db objects. So for this very simple case an insert update flag would do. But as db - domain impedence mismatch increases I would have to refactor to a domain mapper somethign like hibernate which would take care of this.&lt;/p&gt;&lt;p&gt;As of now its pretty much stable demo. It lets you do what you want to. It persists to a database. Thus it does what it claims to.&lt;/p&gt;&lt;p&gt;I pretty much attribute all this to my agile learnings. Agile lets me ask right simple question. Or as these questions a result of my changed mindset? I have to yet to find an answer. ;-)&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;&lt;/p&gt;&lt;p&gt;It must be noted that key is to:&lt;/p&gt;&lt;ol&gt;&lt;li&gt;Take baby steps.&lt;/li&gt;&lt;li&gt;Think on lines of TDD at each and every possible step.&lt;/li&gt;&lt;li&gt;even if not agile use TDD, Refactoring.&lt;/li&gt;&lt;/ol&gt;&lt;p&gt;When this project becomes multi member project: we must:&lt;/p&gt;&lt;ol&gt;&lt;li&gt;Introduce automated builds.&lt;/li&gt;&lt;li&gt;Introudce automated functional tests.&lt;/li&gt;&lt;li&gt;If performance is a major factor right from start, have performance tests in place.&lt;/li&gt;&lt;li&gt;Run functional and performance tests every night.&lt;/li&gt;&lt;/ol&gt;&lt;p&gt;Stay Agile. Stay in Control. Claps.&lt;/p&gt;&lt;p&gt; &lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-110998313408036223?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/110998313408036223/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=110998313408036223&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110998313408036223'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110998313408036223'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/03/changing-mindset.html' title='Changing Mindset'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-110756838355392573</id><published>2005-02-05T07:07:00.000+05:30</published><updated>2005-05-20T03:25:37.456+05:30</updated><title type='text'>Business Knowledge and Software Projects</title><content type='html'>Often in every other project, we can hear the following whispers..at times they get too loud.&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;Developers: We are not getting requirments right.  Typically the expecatation is from requirement gatherers.&lt;br /&gt; &lt;/li&gt;   &lt;li&gt;Requirement gatherers: Customer is not able to give requirments clearly. Typically expectation is from customer.&lt;/li&gt; &lt;/ul&gt; So the flow usually is from developers -&gt; requirement gatherers -&gt; customers. This happens on development projects.&lt;br /&gt;&lt;br /&gt;You may note I have not mentioned business analysts/functional/domain experts. You can get such experts on a project only theoretically. &lt;span style="font-weight: bold;"&gt;Practically you wont get them and dont need them either.&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;There are multiple aspects to this problem:&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;In today' s business scenarios, requirements are never complete. So dont expect as such. But dont accetp ambiguous requirments either. Ambiguity is removed by capturing requirments in code form for developers and non-code form for customer. (FIT) looks like a good starting point.&lt;/li&gt;   &lt;li&gt;Even if you have domain experts if they dont have the skill of capturing requirements then all their knowledge will not help. We must realize every project is to add business value. If business analysts try to have this aim uppermost, many thigns will start falling in place.&lt;/li&gt;   &lt;li&gt;Develoers have to change their mindset of 'we are only gonna code'. Nope you are blessed to do much more than that. Start writing automated tests as verifiction that your code works. Also some of you will convert above FIT tests inot code form. Think and ask questions. Many of them may be silly. But ask and get the answers.&lt;/li&gt; &lt;/ul&gt; So we can see that close colloboration between customers analysts and developers is required as the first step. And second a change of mind set of all three is required.&lt;br /&gt;&lt;ol&gt;   &lt;li&gt;Customers must be willing to put down in provide functional test specs in discussion with specs,&lt;br /&gt; &lt;/li&gt;   &lt;li&gt;business analysts must be willing to learn more about the art of collecting requirments, writing functional tests (even in code form if possible) and&lt;br /&gt; &lt;/li&gt;   &lt;li&gt;developers in automating their unit tests in code.&lt;/li&gt; &lt;/ol&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-110756838355392573?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/110756838355392573/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=110756838355392573&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110756838355392573'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110756838355392573'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/02/business-knowledge-and-software.html' title='Business Knowledge and Software Projects'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-110748379549523955</id><published>2005-02-04T07:35:00.000+05:30</published><updated>2005-02-04T07:56:30.133+05:30</updated><title type='text'>Reading Styles</title><content type='html'>Here's a sample of how I read. Basically how I approach. Please note that these are only&lt;br /&gt;general tips and you will need to make changes as per your requirments.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Reading a Newspaper&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;&lt;/span&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;&lt;/span&gt;&lt;/span&gt;The articles of interest for me are typically columns, edits and analysis types. (You may see&lt;br /&gt;I have an Indian Express hangover :-). I typically just rush through current news. Suprisingly&lt;br /&gt;I dont find anything really interesting to read on top pages. Because they are news. They are&lt;br /&gt;information about what has happened. So just rush skim skip here. The same treatment is meted&lt;br /&gt;out to sports pages.&lt;br /&gt;&lt;br /&gt;Next I move on the more analytical pieces. Here my aim is typically&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;Get main idea&lt;/li&gt;   &lt;li&gt;Register structure&lt;/li&gt;   &lt;li&gt;Either have zero or some awareness of details (this varies). (I will explain different detail awareness levels later).&lt;/li&gt; &lt;/ul&gt; After I have read an article I do this. At times I skip step 4 below as that may not be necessary. I do step 4 for those articles where my control was not to my liking.&lt;br /&gt;&lt;ol&gt;   &lt;li&gt;Recall what is main idea&lt;/li&gt;   &lt;li&gt;Recall the structure&lt;/li&gt;   &lt;li&gt;Just look at each para and try to recall what it says&lt;/li&gt;   &lt;li&gt;Find out how I must have ideally read (OPTIONAL)&lt;br /&gt; &lt;/li&gt;   &lt;li&gt;Register a few difficult words by trying to deduce their meaning. ( I never refer the dict. I think thats the worst way of improving your vocab).&lt;/li&gt; &lt;/ol&gt; Phew so if you spend time like this daily for an hr or so on a good newspaper, its going to make a world of difference.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Reading a Comprehension Piece&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Now  now. Typically RC pieces are dealt with in an aptitude test. GMAT. CAT. SAT. Here first&lt;br /&gt;thing is to have a base strategy for the test in terms of timings. So I have to operate under a time constraint.&lt;br /&gt;&lt;br /&gt;So we move ahead under the assumption that you have a time limit set to yourself. But not being hyper about it. Next I have the following aim while reading an RC:&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;Find out the main idea&lt;/li&gt;   &lt;li&gt;Find out the structure.&lt;/li&gt;   &lt;li&gt;Have some awareness of details.&lt;br /&gt;&lt;/li&gt; &lt;/ul&gt; Then after having read the RC I do this:&lt;br /&gt;&lt;ul&gt;   &lt;li&gt;Recall the main idea&lt;/li&gt;   &lt;li&gt;Go through each para to find out what it says&lt;/li&gt;   &lt;li&gt;In each para, I go through the details trying to get as much as I can.&lt;/li&gt; &lt;/ul&gt; Note that here I dont usually bother to recall the structure (thats already in my head and I also need to save time). Now going through the questions is simpler. Most answers are picked automatically. For a few you need to use elimination, go to the details, or simply find out what my friend Twisted says as 'that which sucks the least'.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Reading a Book&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;This is a new field altogether. Here the challenge is assimilation of more volume of material. Again the differentiating point is "What type of book is it". Why I want to read it.&lt;br /&gt;&lt;br /&gt;So a technical book is read in detail in parts and skimmed in others. Novels are read for pleasure in detail. At times you just want to get the gist of the book. So you skim the entire book.&lt;br /&gt;&lt;br /&gt;I try to see how the book is structured. If it has sections, I see what each section will try to tell me. Then I see what parts of those section appeal to me. And they receive treatment as such.&lt;br /&gt;&lt;br /&gt;The trick is to treat a book as a continous series of small articles and to link up the ideas together.&lt;br /&gt;&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;Details Awareness&lt;/span&gt;&lt;br /&gt;&lt;br /&gt;Zero: You dont care about the details.&lt;br /&gt;Some: You know there is this detail. You can describe it (but not in detail).&lt;br /&gt;Complete: You know the details.&lt;br /&gt;&lt;span style="font-weight: bold;"&gt;&lt;/span&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-110748379549523955?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/110748379549523955/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=110748379549523955&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110748379549523955'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110748379549523955'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/02/reading-styles.html' title='Reading Styles'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-110732889171098602</id><published>2005-02-02T12:48:00.000+05:30</published><updated>2005-02-02T12:53:36.060+05:30</updated><title type='text'>Java and Access Specifiers</title><content type='html'>&lt;!--[if !supportEmptyParas]--&gt;&lt;!--[endif]--&gt;&lt;o:p&gt;&lt;/o:p&gt;  &lt;p class="MsoNormal"&gt;So many times there is confusion about java and its access specifers. Here’s what they mean once and for all.&lt;/p&gt;     &lt;p class="MsoNormal"&gt;&lt;span style="font-weight: bold; font-style: italic;"&gt;Public&lt;/span&gt;: Available to all wherever you may be.&lt;/p&gt;   &lt;p class="MsoNormal"&gt;&lt;span style="font-weight: bold; font-style: italic;"&gt;Private&lt;/span&gt;: Available only to me.&lt;/p&gt;   &lt;p class="MsoNormal"&gt;&lt;span style="font-weight: bold; font-style: italic;"&gt;Protected&lt;/span&gt;: Available to my derived types.&lt;/p&gt;   &lt;p class="MsoNormal"&gt;&lt;span style="font-weight: bold; font-style: italic;"&gt;Friend&lt;/span&gt;: Available to all who belong to my group (package) i.e. are my friends.&lt;/p&gt;   &lt;p class="MsoNormal"&gt;&lt;!--[if !supportEmptyParas]--&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;   &lt;p class="MsoNormal"&gt;Naturally, if I make a class private it can’t be accessed by anyone except the class itself! Now trying make a class protected. Then it will available to only its derived types. But its protected and you cant derive a type. Hence classes don’t have private/protected specifiers. They have only public / friend specifiers.&lt;/p&gt;     &lt;p class="MsoNormal"&gt;However pick any class member and you can safely say it can be either public, private, protected or friend.&lt;/p&gt;     &lt;p class="MsoNormal"&gt;That’s good enough. But real java code will be a mix of public/friend classes with members at different access levels. The matrix is revealed below:&lt;/p&gt;     &lt;p class="MsoNormal"&gt;The following is a list of classes we have:&lt;/p&gt;   &lt;table style="border: medium none ; width: 6.15in; border-collapse: collapse;" border="1" cellpadding="0" cellspacing="0" width="590"&gt;   &lt;tbody&gt;&lt;tr&gt;   &lt;td style="border: 0.5pt solid windowtext; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Class&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 0.5pt 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Access&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 0.5pt 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Package&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;A&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;Public&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;com.test&lt;o:p&gt;&lt;/o:p&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;B&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Public or Friend&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;com.test&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;C extends A&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Public of Friend&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;com.test&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;D&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Public of Friend&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;com.testother&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;E extends A&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Public of Friend&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;com.testother&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt; &lt;/tbody&gt; &lt;/table&gt;     &lt;p class="MsoNormal"&gt;Lets see what members of A are accessible to what members of B, C, D, E. Classes B, C are in same package as A while D, E are outside of the package that A belongs to.&lt;/p&gt;     &lt;table style="border: medium none ; border-collapse: collapse;" border="1" cellpadding="0" cellspacing="0"&gt;   &lt;tbody&gt;&lt;tr&gt;   &lt;td style="border: 0.5pt solid windowtext; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Non static members of A&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 0.5pt 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Can be accessed by&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 0.5pt 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Can be overridden by&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Public&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;B, C, D, E&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;C, E&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Protected&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;C, E&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;C, E&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Friend&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;B, C&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;C&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Private&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;None&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;None&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt; &lt;/tbody&gt; &lt;/table&gt;     &lt;p class="MsoNormal"&gt;Now lets apply the above to a friend class.&lt;/p&gt;     &lt;p class="MsoNormal"&gt;The following is a list of classes we have:&lt;/p&gt;     &lt;table style="border: medium none ; border-collapse: collapse;" border="1" cellpadding="0" cellspacing="0"&gt;   &lt;tbody&gt;&lt;tr&gt;   &lt;td style="border: 0.5pt solid windowtext; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Class&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 0.5pt 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Access&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 0.5pt 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Package&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in; font-weight: bold;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;F&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in; font-weight: bold;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Friend&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in; font-weight: bold;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;com.test&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;G&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Public or Friend&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;com.test&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;H extends F&lt;br /&gt;&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Public of Friend&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;com.test&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt; &lt;/tbody&gt; &lt;/table&gt;     &lt;p class="MsoNormal"&gt;Naturally here I consider classes only in same package as F.&lt;/p&gt;     &lt;p class="MsoNormal"&gt;Lets see what happens here.&lt;/p&gt;     &lt;table style="border: medium none ; border-collapse: collapse;" border="1" cellpadding="0" cellspacing="0"&gt;   &lt;tbody&gt;&lt;tr&gt;   &lt;td style="border: 0.5pt solid windowtext; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Non static members of F&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 0.5pt 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Can be accessed by&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: solid solid solid none; border-color: windowtext windowtext windowtext -moz-use-text-color; border-width: 0.5pt 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;&lt;b&gt;&lt;u&gt;Can be overridden by&lt;o:p&gt;&lt;/o:p&gt;&lt;/u&gt;&lt;/b&gt;&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Public&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;G, H&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;H&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Protected&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;H&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;H&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Friend&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;G, H&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;H&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt;  &lt;tr&gt;   &lt;td style="border-style: none solid solid; border-color: -moz-use-text-color windowtext windowtext; border-width: medium 0.5pt 0.5pt; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;Private&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;None&lt;/p&gt;   &lt;/td&gt;   &lt;td style="border-style: none solid solid none; border-color: -moz-use-text-color windowtext windowtext -moz-use-text-color; border-width: medium 0.5pt 0.5pt medium; padding: 0in 5.4pt; width: 2.05in;" valign="top" width="197"&gt;   &lt;p class="MsoNormal"&gt;None&lt;/p&gt;   &lt;/td&gt;  &lt;/tr&gt; &lt;/tbody&gt; &lt;/table&gt;     &lt;p class="MsoNormal"&gt;Note that static public members of F can be accessed outside the package !&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-110732889171098602?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/110732889171098602/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=110732889171098602&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110732889171098602'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110732889171098602'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/02/java-and-access-specifiers.html' title='Java and Access Specifiers'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-110678671676078616</id><published>2005-01-27T05:34:00.000+05:30</published><updated>2005-01-31T02:33:48.926+05:30</updated><title type='text'>Why refactoring helps?</title><content type='html'>Take a look. I had this requirment:&lt;br /&gt;We conduct polls (which can be looked at like permanent polls). We gather monthly statistics. We want to :&lt;br /&gt;&lt;ul&gt;&lt;li&gt;find out votes cast till a month say Jun 2005&lt;br /&gt;&lt;/li&gt;&lt;li&gt;find out votes cast for a quarter of a finanical year say Quarter 1 for 2004 - 2005&lt;/li&gt;&lt;li&gt;find out votes cast for a half yearly of a financial year say half year 1 for 2004 - 2005&lt;/li&gt;&lt;li&gt;find out votes cast for a fin year say 2004 - 2005.&lt;/li&gt;&lt;/ul&gt;Then the user told me "hey we capture votes in various forms, for me the most erratic turned out to be Money". So I started with that.&lt;br /&gt;&lt;br /&gt;To start off I started without implementing any classes but with junit test cases which looked like:&lt;br /&gt;&lt;br /&gt;PollTest {&lt;br /&gt;setUp() {//this also came out of refactoring but I wont go into it&lt;br /&gt;newPoll = new Poll("X");&lt;br /&gt;aprData = new MonthlyData("apr 2004", new Money(265, USD)); //This money looks good //:-)&lt;br /&gt;mayData = new MonthlyData("may 2004", new Money(335, USD));&lt;br /&gt;//and so on for mths till Mar 2005&lt;br /&gt;newPoll.addMonthlyData(aprilData);&lt;br /&gt;newPoll.addMonthlyData(mayData);&lt;br /&gt;//and so on for mths till Mar 2005&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;testOneMthBalance() {&lt;br /&gt;assertEquals(new Money(265, USD), newPoll.getBalanceTill("apr 2004"));&lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;testTwoMonthsBalance(){&lt;br /&gt;assertEquals(new Money(600, USD), newPoll.getBalanceTill("may2004");&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;//and so on for newPoll.getQuarterlyBalance(quareterNo, financialYear)....&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;Note: I write one test method , see the red bar in junit, then implement that and see the green bar in junit. After writing methods for all such balances reqd, my code in poll class looked like:&lt;br /&gt;&lt;br /&gt;Poll {&lt;br /&gt;List monthlyData;&lt;br /&gt;&lt;br /&gt;public Money getBalanceTill(Date mth) {&lt;br /&gt;Iterator e = monthlyData.getIterator();&lt;br /&gt;Money balance = new Money(0, USD);&lt;br /&gt;while(e.hasnext() ) {&lt;br /&gt;MonthlyData eachData = (MonthlyData)e.next();&lt;br /&gt;if(! eachData.getMth().after(mth)) {&lt;br /&gt;balance = balance.add(eachData .getVotes());&lt;br /&gt;}&lt;br /&gt;return balance;&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;//Note below: I look at a financial year as a range, hence the Range pattern.makes life easy&lt;br /&gt;public Money getQuarterlybalance(int quarter, DateRange finYear) {&lt;br /&gt;Iterator e = monthlyData.getIterator();&lt;br /&gt;Money balance = new Money(0, USD);&lt;br /&gt;//This method gives me range(apr 2004 to jun 2004) for quarter = 1 of 2004 - 2005 fin&lt;br /&gt;//year&lt;br /&gt;DateRange quarterRange = financialYearUtility.getQuarter(quareterNo, finyear);&lt;br /&gt;while(e.hasnext() ) {&lt;br /&gt;MonthlyData eachData = (MonthlyData)e.next();&lt;br /&gt;if(quarterRange .contains(eachData.getMth()) {&lt;br /&gt;balance = balance.add(eachData .getVotes());&lt;br /&gt;}&lt;br /&gt;return balance;&lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public Money getHalfYearlyBalance(int halfyearno, DateRange finYear) {&lt;br /&gt;Iterator e = monthlyData.getIterator();&lt;br /&gt;Money balance = new Money(0, USD);&lt;br /&gt;//This method gives me range(apr 2004 to sep 2004) for half year= 1 of 2004 - 2005 fin&lt;br /&gt;//year&lt;br /&gt;DateRange halfYearRange= financialYearUtility.getHalfYear(halfyearno, finyear);&lt;br /&gt;while(e.hasnext() ) {&lt;br /&gt;MonthlyData eachData = (MonthlyData)e.next();&lt;br /&gt;if(halfYearRange.contains(eachData.getMth()) {&lt;br /&gt;balance = balance.add(eachData .getVotes());&lt;br /&gt;}&lt;br /&gt;return balance;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;public Money getYearlyBalance(DateRange finYear) {&lt;br /&gt;Iterator e = monthlyData.getIterator();&lt;br /&gt;Money balance = new Money(0, USD);&lt;br /&gt;while(e.hasnext() ) {&lt;br /&gt;MonthlyData eachData = (MonthlyData)e.next();&lt;br /&gt;if(finYear.contains(eachData.getMth()) {&lt;br /&gt;balance = balance.add(eachData .getVotes());&lt;br /&gt;}&lt;br /&gt;return balance;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;PS: This is also extracted sample code.&lt;br /&gt;&lt;br /&gt;&lt;ul&gt;&lt;li&gt;After all this pain, junit was turning green. I had small classes like Poll, MonthlyData, &lt;a href="http://www.martinfowler.com/ap2/range.html"&gt;DateRange&lt;/a&gt;, FinancialYearUtility (to give me ranges I wanted), DateRange, &lt;a href="http://www.martinfowler.com/eaaCatalog/money.html"&gt;Money&lt;/a&gt;. I was happy. Nah. &lt;/li&gt;&lt;li&gt;&lt;span style="FONT-WEIGHT: bold"&gt;Whenever I looked at above four methods I wasnt. I knew I could reduce them. But couldnt. Then suddenly it struck me&lt;/span&gt;. Look closely. All four methods iterate the monthly list.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;For those mths whcih fall within a range, it gives me the balance. I started off with getBalanceTill(mth) and all following methods pretty much did the same.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;For getBalanceTill method, I figured out its nothing but corresponding fin year start mth - to given mth. Bingo. Now my 4 methods looked like this:&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;Poll {&lt;br /&gt;&lt;br /&gt;private Money getBalanceFor(DateRange range) {&lt;br /&gt;Iterator e = monthlyData.getIterator();&lt;br /&gt;Money balance = new Money(0, USD);&lt;br /&gt;while(e.hasnext() ) {&lt;br /&gt;MonthlyData eachData = (MonthlyData)e.next();&lt;br /&gt;if(range.contains(eachData.getMth()) {&lt;br /&gt;balance = balance.add(eachData .getVotes());&lt;br /&gt;}&lt;br /&gt;return balance;&lt;br /&gt;&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public Money getBalanceTill(Date mth) {&lt;br /&gt;return getBalanceForRange(financialYearUtility.getRangeFor(mth));&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public Money getQuarterlyBalance(int quarterNo, DateRange finYear) {&lt;br /&gt;return getBalanceForRange(financialYearUtility.getQuarter(quarterNo, finYear));&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public Money getHalfYearlyBalance(int halfYearlyNo, DateRange finYear) {&lt;br /&gt;return getBalanceForRange(financialYearUtility.getHalfYear(halfYearlyNo, finYear));&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;public Money getYearlyBalance(DateRange finYear) {&lt;br /&gt;return getBalanceForRange(finYear);&lt;br /&gt;}&lt;br /&gt;}&lt;br /&gt;&lt;br /&gt;Note:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;span style="FONT-WEIGHT: bold"&gt;I was very happy because it reduced lines of code and made code more simpler&lt;/span&gt;. My pair partner (a learner ;-) aruged getYearlyBalance and getBalanceFor(range) methods are same. I said yes.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;But I went for transparency than reducing even more lines of code because that would make the code confusing.&lt;br /&gt;&lt;/li&gt;&lt;li&gt;He asked how and I said if year mthd does the task of calculating balances then halfyearly method looks like:&lt;/li&gt;&lt;/ul&gt;&lt;br /&gt;public Money getHalfYearlyBalance(int halfYearlyNo, DateRange finYear) {&lt;br /&gt;return getYearlyBalance(financialYearUtility.getHalfYear(halfYearlyNo, finYear));&lt;br /&gt;} // i will go nuts if i read something like this&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;So you got to judge the values of refactorings. First up, refactoring is letting u enable DRY (&lt;span style="FONT-WEIGHT: bold"&gt;Dont Repeat Yourself&lt;/span&gt;) principle. At the same time keep looking for writing maintainable code.&lt;br /&gt;&lt;br /&gt;Surprising aint it, that when I get into projects which force me to write procedural code in Java, I SUCK BIG TIME&gt; but i m happy (that means I cant move away from OO code :-). Some things in life cant be explained.&lt;br /&gt;&lt;br /&gt;This learner friend of mine remarked "No probs if you are arrogant about your OO Skills. Be like that. Its FUN" :-)&lt;br /&gt;&lt;br /&gt;Anyone wants to expand Money class and handle all conversions is welcome. I am more than glad. :-P. Anyone wants to learn Refactoring, TDD give me a shout.&lt;br /&gt;&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-110678671676078616?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/110678671676078616/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=110678671676078616&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110678671676078616'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110678671676078616'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/01/why-refactoring-helps.html' title='Why refactoring helps?'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-110540190203047830</id><published>2005-01-11T05:25:00.000+05:30</published><updated>2005-01-11T05:35:02.030+05:30</updated><title type='text'>No New Year Resolutions for Me</title><content type='html'>Every time a new year dawns and people come up with resolutions. Though I am not the kind of person who can do it with resolutions. I cannot decide anything at the spur of a moment and go for it. I though must point out that I apply this constraint to professional matters ;-)&lt;br /&gt;&lt;br /&gt;The problem I find with resolutions is that there is not sufficient thought thats gone behind it. Its like a fashion statement. With time it fades away. On the contrary, I find it much better to measure what I have done every month or so. And very strictly every quarter. That is strictly to gauge where I am versus where I could be.&lt;br /&gt;&lt;br /&gt;Also I use the new year as a year end review to find out if I have met the milestones I set. But these milestones are not resolutions. They are strictly thought out, refined and finalized. I typically do that in the last 2 weeks of Dec with the feedback of monthly, quarterly reviews. So its thought and planned. Not resolution.&lt;br /&gt;&lt;br /&gt;Regarding reviews I keep them plain simple. I use an excel document with worksheets for personal/professional targets. Personal targets are also professional activities but outside the domain of my daily work! I keep checking my status, keep purging out those activities which may not be worth it. I am pretty much using XP feedback techniques. Just one excel sheet and regular positive thinking has helped me.&lt;br /&gt;&lt;br /&gt;So if your resolutions are backed up with thoughts and flexible planning then great. So also I would say milestones without thoughts / feedback are worthless. Thus its your thinking and flexible planning that matter.&lt;br /&gt;&lt;br /&gt;Have a Great Year Ahead.&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-110540190203047830?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/110540190203047830/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=110540190203047830&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110540190203047830'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110540190203047830'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2005/01/no-new-year-resolutions-for-me.html' title='No New Year Resolutions for Me'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-110219172419237547</id><published>2004-12-05T02:43:00.000+05:30</published><updated>2004-12-05T01:52:04.193+05:30</updated><title type='text'>Learning Tips</title><content type='html'>&lt;p&gt;Learning I believe never stops. Only the rate of learning. If you are conscious about your learning, great. But the biggest change comes about when people get into jobs. Somehow there is the impression, once again from the mechanical industry, that your learning, education is where you spend time learning. And the fruit of that is a job where you are not supposed to learn.&lt;br /&gt;&lt;br /&gt;But the knowledge industry has changed that. Here learning is the most essential key and even more important is the fact that you apply your learnings efficiently. The key then becomes is how do you keep learning juggling your personal, professional needs. I for one believe that yes one will keep learning on the job. Still its very necessary to have a focussed learning plan in place. The only hitch is making the right plan especially with the demands on one's time.&lt;br /&gt;&lt;br /&gt;&lt;u&gt;Here the following few learning tips may help:&lt;/u&gt; &lt;/p&gt;&lt;ol&gt;&lt;li&gt;Be as motivated as a child is to learn. Don’t forget that there is a child within you. Keep it alive.&lt;/li&gt;&lt;li&gt;Learn at small, regular intervals. Keep yourself fresh always for learning.&lt;/li&gt;&lt;li&gt;Make learning fun by tracking your progress.&lt;/li&gt;&lt;li&gt;Maintain the tempo in later stages of learning when "law of diminishing returns" starts making itself felt.&lt;/li&gt;&lt;li&gt;Use your brain always. Don’t forget your heart though :-)&lt;/li&gt;&lt;li&gt;There will be phases in learning where you show little or no progress. Persevere.&lt;/li&gt;&lt;/ol&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-110219172419237547?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/110219172419237547/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=110219172419237547&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110219172419237547'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110219172419237547'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2004/12/learning-tips.html' title='Learning Tips'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-110119251061024654</id><published>2004-11-23T12:06:00.000+05:30</published><updated>2004-11-23T12:18:30.610+05:30</updated><title type='text'>IIM CAT 2004 - The wounded lion roars back</title><content type='html'>Why the big fuss? That questions carry unequal marks, we dont know the proportion of negative marks etc. CAT = Certainly Abnormal Test. CAT 2004 for sure made everyone realize what to expect "Dont expect" ;-)&lt;br /&gt;&lt;br /&gt;Anyways a huge change was anticipated. How short our memories are? CAT 2003 was held again in Feb 2004 because some Don played Cat and Mouse with the IIMs reputation. So the lion had to roar back. And it did roar :-). This was one key factor that was conscipous by its absence on the infinite chat transcripts I read :-(&lt;br /&gt;&lt;br /&gt;Finally coming to strategizing, the key element in CAT has always been coming up with a base plan when you get the sealed paper, and at runtime fine tuning it. So much like what a manager does and doesnt in real life. And the few who do in software turn XPers. Coming back to the point, in 2004 the fact that questions carried unequal marks zapped the ground under every candidates feet.&lt;br /&gt;&lt;br /&gt;Till now it has been that CAT always had 1 mark questions. So strategizing was pretty simple. Thus if I have say 3 sections of 55 questions each, I could say it was 55 marks each. For 120 mins, my base plan would be 40 mins per section, saving 5 mins on easy section and using that on the other tough section. Even when the number of questions are unequal say 45, 45, 30, 35 across 4 sections, my base plan would be 35, 35, 25, 25 mins for the 4 sections and again gaining some time in easier, oops less tougher, sections and utilizing that in other tougher sections.&lt;br /&gt;&lt;br /&gt;However this time the catch was unequal questions and unequal marks. But common sense tells me that I must allocate time primarily on the basis of marks per question. So if x mins for 1 mark question, it moves to 2x for 2 mark and 0.5x for 0.5x marks question. Remember this is only for coming up with a base plan. Thus when I get CAT 2004 in hand, first I must not panic. Thats the universal rule. Next I see there are 3 sections and 2 subsections in each. Thus at first glance base plan is 20 mins per subsection. But I see questions carry unequal marks. And total marks is 150. So for section A which has 26 1 mark questions and 12 - 2 mark questions it translates to 26 Mark subsection, 24 mark subsection. Immediately its 20 mins per subsection. And it makes sense because 20 mins for easy to medium 26 questions and 20 mins for 12 difficult questions. Also attempting 12-13 1 mark questions and 4-5 2 mark questions in 35 mins would give me a fair idea. If I know its good enough to clear the cut off I move on to section 2. ANd so on and on for other sections.&lt;br /&gt;&lt;br /&gt;Finally the key to this CAT was alloting time not just on basis of questions but on the marks alloted also. The CAT drank your milk of wisdom and common sense eh :-)&lt;br /&gt;&lt;br /&gt;&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-110119251061024654?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/110119251061024654/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=110119251061024654&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110119251061024654'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110119251061024654'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2004/11/iim-cat-2004-wounded-lion-roars-back.html' title='IIM CAT 2004 - The wounded lion roars back'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-110028658483579929</id><published>2004-11-13T00:29:00.000+05:30</published><updated>2004-11-13T00:39:44.836+05:30</updated><title type='text'>Personality Types</title><content type='html'>I was going through a chapter of Norman Lewis Reading Faster. Here he talks about personality types and their reading habits. And immediately I started to think if there is a link between personality types and XP. Because what is XP but a set of habits that people on the Xp project have. Habit of writing tests first, habit of automating tests, habit of domain design, habit of integrating continuously. Habits and more habits. :-)&lt;br /&gt;&lt;br /&gt;But the biggest habit is to be not a perfectionist. The habit of getting along, plugging ahead with whatever you have. So the immediate draw is "Dont be a perfectionist if you have to work on XP Project". But then we form our habits and then we dont want to experience the pain of changing it. And I had a first experience of explaining one of my friends about XP's TDD. He was so much habitutated of being upfront first, he could never get to the point of learning TDD. But then he may be an Xtreme example :-)&lt;br /&gt;&lt;br /&gt;Finally the first thing before you venture into agile, you need to find out about your habits. Whether they will help you in your tryst of writing better software (I assume thats the reason why wanna XP).  If you are habituated to keep it simple, move ahead, not regress then your transition may be smooth. But if not, you are a perfectionist, upfronter then work on changing your habits and then work on learning XP. I bet you will enjoy the success.&lt;br /&gt;&lt;br /&gt;XP many times I feel is not just a way of programming its a way of life. Somewhere I See a higher from lurking, Xtreme Living probably which can be abbreviated to XL. Yes just as XP gives you the chance to XL at programming, so may XL let you xcel in your life. Happy Living. :-)&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-110028658483579929?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/110028658483579929/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=110028658483579929&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110028658483579929'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/110028658483579929'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2004/11/personality-types.html' title='Personality Types'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-109928343942954209</id><published>2004-11-01T09:53:00.000+05:30</published><updated>2004-11-01T10:00:39.430+05:30</updated><title type='text'>Is Xtreme Programming the next Strategic Inflection point?</title><content type='html'>The other day I was reading Andrew S Grooves "Only the Paranoid Survive". This book basically talks about those points one faces in career or buisiness ( I know nothing there) which do a volte-face. Everything that seemed so right till yesterday has changed completely.&lt;br /&gt;&lt;br /&gt;Andrew talks about PC and Internet, the two inflection points which have impacted both careers and business in a profound way. And he also says that to handle these crisis points or strategic inflection points, one needs always to be on the alert and keep experimenting. That got me thinking.&lt;br /&gt;&lt;br /&gt;All of a sudden XP dawned upon me. Is it a strategic inflection point? AS of now I cant conclude assertively but many of the observations do point to that. If XP really succeeds and takes root, its gonna change the way software is written on a large scale. Currently its limited to some courageous projects.  It will be a topsy turvy, a huge change for every IT professional. It can make outsourcing look silly or make it even stronger if the Business Process Outsourcing succeeds. THen customers being closer to project team is a reality at offshore and not onsite! Whatever, only time will tell, but yes, I do think that XP may be the next infleciton point.&lt;br /&gt;&lt;br /&gt;What then should a career professional do? And a business? For a latter I neither have the data nor the resources to predict. For a career, first thing is that each professional has to develop a learnign attitude. For most, people see an IT career as a non-learning job which is dangerous. Next you have to start learning about agile principles and the alternative way of writing software so that if the inflection point does rear its ugly head, you are better positioned to make the transition.&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-109928343942954209?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/109928343942954209/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=109928343942954209&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/109928343942954209'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/109928343942954209'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2004/10/is-xtreme-programming-next-strategic.html' title='Is Xtreme Programming the next Strategic Inflection point?'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-109829914076225815</id><published>2004-10-21T01:30:00.000+05:30</published><updated>2004-10-21T00:35:40.763+05:30</updated><title type='text'>I "WILL"</title><content type='html'>While reading how to read better and faster by Norman Lewis, I learnt a big lesson. Which I had learnt earlier also. But then its always good to revise. The difference between "will" and "wish". I realized that in many projects we say "wish we had automated tests, wish we had  continous builds" etc. But we dont anything. Why? Because we dont really want to change or are "will"ing to put the efforts and bear the pain of change.&lt;br /&gt;&lt;br /&gt;So I thought that why I picked up this book?Because I "willed" to upgrade my reading skills. Hence If I "will", I can introduce automated tests etc in any project I join. Yes I will face a few difficulties, but then I can find a way out if I "Will". But if I "wish" these difficulties are going to shut me off.&lt;br /&gt;&lt;br /&gt;As a start then I am writing a simple finance calculator application which puts into practice refactoring, automated tests, continous builds. I "will" do it because I realize that only if I "will" I can change. I wish many others learn this lesson. Ooops I "will" :-)&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-109829914076225815?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/109829914076225815/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=109829914076225815&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/109829914076225815'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/109829914076225815'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2004/10/i-will.html' title='I &quot;WILL&quot;'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-109823190452910085</id><published>2004-10-20T05:46:00.000+05:30</published><updated>2005-02-04T07:35:21.746+05:30</updated><title type='text'>Reading Better and Faster</title><content type='html'>Of late I am back to getting skilled at my interest of reading. Reading is one of the best ways to keep one informed. And to keep yourself informed, you also need to read a variety of material. People I find who read a variety of material are those who have developed good reading habits.&lt;br /&gt;&lt;br /&gt;To develop these habits for self, I picked what else but the Reading Manual by Norman Lewis. While practising through this, I find one of my old lessons handy. Its never the quantity of practice, but the quality of your practice is what matters. So after reading a selection I re-read the selection to find out "how actually I must have read". Thats my semantic gap. And with each selection my aim is to reduce the gap. That is my first attempt to master a page of print must be the ideal approach.&lt;br /&gt;&lt;br /&gt;Till now I am just at the very beginning, but I have developed these rules:&lt;br /&gt;&lt;br /&gt;&lt;ol&gt;&lt;li&gt;Be relaxed. Define the purpose of your reading. &lt;/li&gt;&lt;li&gt;Allocate a time limit. This develops URGENCY. &lt;/li&gt;&lt;li&gt;Start a bit slowly to gain a foothold. And &lt;/li&gt;&lt;li&gt;Aggressively look for main ideas and sense the structure. This develops CONCENTRATION.&lt;/li&gt;&lt;li&gt;Dont ever take your eyes off the reading material. &lt;/li&gt;&lt;li&gt;Dont ever ever regress. Keep plugging ahead. &lt;/li&gt;&lt;li&gt;Minimize inner speech to the extent possible. Dont shut it off however. Dont be conscious of your eye movements either.&lt;/li&gt;&lt;li&gt;If you are sensing structure correctly, you will know which paras are main ideas and which deal with extensions of an idea/details. Partially skim such paras. Go fast on them. Read carefully main idea related paras.&lt;/li&gt;&lt;li&gt;Practice slight skimming conscientiously. Use partial/complete skimming judiciously.&lt;/li&gt;&lt;li&gt;Scribble notes if required, but not at the cost of breaking your rythm.&lt;/li&gt;&lt;li&gt;Approach material skeptically. Think actively. Anticpate. Except. Though not each one may be fufilled, it will keep you involved in the activity of reading.&lt;/li&gt;&lt;li&gt;Ask follow up questions. Think about what you have read. And how much sense it makes to you. :-). By sense how much multi dimensional you can be about the topic.&lt;br /&gt;  &lt;/li&gt; &lt;/ol&gt;&lt;br /&gt;&lt;p&gt;Whatever be your purpose, getting hold of the main idea and sensing the structure is very important. Further take into account difficulty level of reading material. I have seen that an author usually writes at the same level of difficulty. Its it this context that point 3 is so important. Its like driving. You dont start the car at 60 mph. You increase gradually. And when you hit barriers, you slow down. So goes with reading.&lt;/p&gt;&lt;p&gt;Next point to note is what you are reading. Reading a newspaper is different from reading a book. Add to it why you are reading?Newspaper is for being aware of current affairs. Again within that finance may matter more to you than politics. So different articles in the newspaper will receive different treatments. Also with books. Some books you will study in detail completely. Some just to get an idea. Some in detail in parts and skimming in others. Be very clear about why you are reading?What you expect out of it?Then reading becomes simpler. Its like that 'if you dont know where u wanna go, you wont reach there' :-)&lt;/p&gt;&lt;p&gt;Also some people like me (XPers) will like to read iteratively. Others prefer a single go. Whatever, note that being aware of whether you are into a main idea, an extension, detail is very important. Just like driving again. If you dont know whether you are in a parking lot, freeway, street road, you wont adjust your driving speed. Thats why I am wary of insane or less aware drivers. :-). So skip the next two paras if you are not or dont intend to be an iterative reader.&lt;/p&gt;&lt;p&gt;Eventually I also find that at times stopping a bit and thinking for a few factional seconds doesnt harm. In fact that stop lets you re-group. I remember "Slow and steady wins the race". So when Norman says fast, aggressive and such other terms, he implies be the tortoise and not the rabbit. &lt;/p&gt;&lt;p&gt;To update I would say that this &lt;strong&gt;&lt;u&gt;stop&lt;/u&gt;&lt;/strong&gt; should come only after the first round of reading where you have mastered the central idea and the structure of the passage. Its not meant in the sense of stopping while reading. This is because typically your purpose will vary always. When you are attempting say an aptitude test, your purpose is different is compared to that when you want to study the material. But in all purposes, one higher purpose is to "get the main idea and register the structure". So its like understanding the forests before diving into the trees. The way you do navigations, from an overview level to details. Further doing the first will help you to actually dive into those areas where you need to depending upon your purpose. &lt;/p&gt;&lt;p&gt;&lt;a href="http://www.alibris.com/search/search.cfm?qwork=3027537&amp;wauth=Lewis%2C%20Norman&amp;amp;ptit=How%20to%20read%20better%20and%20faster&amp;pauth=Lewis%2C%20Norman&amp;amp;pisbn=&amp;pqty=15&amp;amp;pqtynew=0&amp;pbest=9%2E90&amp;amp;matches=15&amp;amp;qsort=r"&gt;This book is a must read for everyone. &lt;/a&gt;&lt;/p&gt;&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-109823190452910085?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/109823190452910085/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=109823190452910085&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/109823190452910085'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/109823190452910085'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2004/10/reading-better-and-faster.html' title='Reading Better and Faster'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8176680.post-109415457319610258</id><published>2004-09-03T02:18:00.000+05:30</published><updated>2004-11-23T12:22:48.670+05:30</updated><title type='text'>I am blogging</title><content type='html'>&lt;span style="font-family:georgia;"&gt;This is the start of my blogging days. I hope this blogspot lets me blog comfortably. With so much going on, its necessary I get the load off me. And one of the coolest ways I feel is by writing.&lt;br /&gt;&lt;br /&gt;Writing is an amazing skill taught to me by my dad. Writing makes everythign so clear. Have an idea, write it down. And the words on the paper solve your problem.&lt;br /&gt;&lt;br /&gt;Thanks Dad. &lt;/span&gt;&lt;br /&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8176680-109415457319610258?l=deepaksurti.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://deepaksurti.blogspot.com/feeds/109415457319610258/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8176680&amp;postID=109415457319610258&amp;isPopup=true' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/109415457319610258'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8176680/posts/default/109415457319610258'/><link rel='alternate' type='text/html' href='http://deepaksurti.blogspot.com/2004/09/i-am-blogging.html' title='I am blogging'/><author><name>Deepak Surti</name><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='32' height='32' src='http://1.bp.blogspot.com/-RO7aly9PAcA/TtiHSrYED_I/AAAAAAAAAE4/BaIGlkR_HkE/s220/elephant.png'/></author><thr:total>0</thr:total></entry></feed>
