Tuesday, April 27, 2010

Teaching 10 times Vs Teaching Basics Once

I have seen many teachers who are ready to teach a topic 10 times, if the student does not understand it. But, most of them miss the point that, if the student does not understand even after teaching second time, it means, there is some thing wrong. Most of the time, the student does not have the basics of that topic, and that's why he/she could not understand. The student should be taught on the basics of that topic, and then only he/she can understand. Without teaching basics, if they keep on teaching the same topic even for 100 times, they will not understand, and the student may lose confidence and then interest on the subject.

Learn Basics and Teach Basics.

Saturday, April 24, 2010

Copy Right - Is Registration Mandatory?

Most of the articles that I have read says, if I publish anything that I own, that itself is proof enough that, it is copyrighted to me. Once I copyright anything, then nobody can use that without taking permission from me.

Recently, in one discussion in a TV Channel, Loksatta's Legal Cell Convenor C.V.L.Narasimha Rao told that, just publishing itself is not enough for copyright, and one must register it to copyright it. He said, just publishing cannot be produced as a proof in the court. Due to few other issues, the discussion did not continue on that line.

Few months back, I had met C.V.L.Narasimha Rao to discuss whether there can be any way, I can proceed legally for the issues that I mentioned in the article Is it Legal or Illegal?. He told me, what are all involved in any case. For the transport problem, the court would ask questions like,

how many buses are there?
how many passengers are there?
What is the capacity of the bus?
Which routes have problems?
How many buses are required in those routes?
Whether there was any complaint given to RTC for this?
What did they say?
Whether the issue was escalated to the Managing Director?
What did the MD say?

For any of these questions, if the response is negative or does not have supporting documentation, the court would dismiss the case immediately. Not only that, court does not involve in changing any act. If there is any problem, then court would just ask to solve that problem, and it does not involve in solving root problems or solving for long term, which is the duty of Assembly/Parliament.

Based on the above experience, I could easily understand the problems in filing a court case on copyright without registering it. Even if they publish it, still they need to prove that, they have created that content on that day or before, which is not trivial. Even if one person publishes a book, how do they prove that, that book was published in the year mentioned in that book? It is not very trivial. Theoretically, just publishing may be enough to copyright it. But, in practical, it may not be enough. So, it is better to register it to copyright.

On a side note, all the creations of all the employees of almost all the corporate companies would belong to the corresponding companies, and not to the actual person who created it. Since, almost all the companies write in their agreements that, all the creations of the employee would belong to the company, irrespective of whether it is done during the office time or not.

Wednesday, April 21, 2010

KPAstrology.org (In Telugu)

Sri Adigopula Siva Sankara Rao has developed a tutorial for Astrology (KrishnaMurthy Paddathi) in Telugu. It has all the information about KP Astrology. The tutorial is available at KPAstrology.org. For any suggestions or questions on KP Astrology, please contact Sir Sankara Rao at 93939 55000.

Sunday, April 18, 2010

How do the managers force their Favorite Technologies?

A Manager comes up with some technology which he/she wants to use. He/She learns few buzzwords in that technology and proposes it.

Developers do not know how to respond to that. For any question by any developer, the manager throws some buzzword in the marketing guide of that technology, and says, with that technology, one can do everything.

Developers cannot reply to the manager, because, the manager knows more buzzwords than the developers.

When developers are not in agreement with the manager in using the new technology, the manager tells them that, it is only a proposal and not the final design.

For verifying this proposal, the manager asks the developers to start prototyping.

If the developers fail in prototyping, the manager googles the corresponding keywords and sends the top 10 results to the developers, and asks them why they could not search in google.

If atleast one developer could manage the prototype of his/her component, then the manager is impressed by that developer. If any other developer fails in his/her component, the manager asks the developer who was successful to help this developer.

Once everyone finishes the prototyping of their respective components, and if all the developers unanimously say that, this technology is not good for the product, since it is taking more time and effort, then the manager says the following:

"Why are you telling me this now? We are already in the middle of the release. We have spent lot of time and effort in this technology. If we change the technology, then we cannot deliver by the deadline, and all the effort would be wasted."

With that, the developers unwillingly use the technology proposed by the manager.

Thursday, April 15, 2010

Minimum Matches To Win In IPL To Enter Semi-Finals

In IPL (till 2010), there are 8 teams. Each team plays with all other teams twice. The top 4 teams would go to semi-finals. If two teams get equal no.of points, then the one which has higher Net Run Rate would get better rank.

How many minimum no.of matches should a team win to enter semi-finals in the best case as well as worst case? Assume that, in all the matches, one team would win, and there is no case of draw/tie/cancellation.

Each team plays 14 matches. Generally, people tend to think that, if any team wins one more match than the half, then it would surely go to semi-finals. i.e., if a team wins 8 matches then it would enter semi-finals. But, that is not the case.


[In the above table, for any cell, if there is a W/L, it means, the team in that row won/lost against the team in that column.]

In the above case, teams 1,2,3,7 and 8 won 5 games each. Since, each team plays with all other teams twice. In the second round also, if they win exactly like this, and there will be five teams with 10 wins each. So, even if a team wins 10 games, it is not guaranteed that it would reach semi-finals.


In the above table, 1, 2 and 3 reach semi-finals. 4, 5, 6, 7 and 8 have won 2 matches each. If the same is repeated in the second round also, then one of 4, 5, 6, 7 and 8 would reach semi-finals with just 4 wins.

Wednesday, April 14, 2010

NTR and Rajanala

This is from the book All In One by Omkar.

It is not known whether this story is real or not. But, this is very popular in the telugu cinema industry.

Once NTR and Rajanala accepted to make a movie under a new director. On the first day itself, both NTR and Rajanala understood that this new director does not have talent to make a movie. One day, when the director told a shot, Rajanala was about to give suggestion that, it would confuse the audience. NTR stopped Rajanala and told him that, director knows it, and asked him to come outside.

After coming outside, Rajanala asked NTR, whether what he told was not correct. NTR said to him, "I know it. We already know the capacity of this director. If we give suggestions to him, he will make this movie a success and makes another 10 movies, and by that many producers will be bankrupt. If we leave him now, he will leave with this film."

Sunday, April 11, 2010

Non-Microsoft Softwares Vs Microsoft Softwares

There are 11 kinds of people.

  • Those who like Microsoft Softwares.
  • Those who do not like Microsoft Softwares.
  • Those who do not know anything about Software.

Most of the time, the discussion between Windows and Linux, Free softwares and Microsoft softwares, would lead to religious debate (if both the parties have equal knowledge in their respective domains, then the debate will never end).

Some times, I would see while debating, they expose all the negative aspects of the product they support.

Some time back, one person (who supports Microsoft softwares) explaining that, SQL Server has a nice feature. It has an isolation level Read Uncommitted which is exclusive for SQL Server and not available in Oracle. I was feeling like laughing for that (but did not laugh because of various reasons).

SQL Server:
Read Uncommitted:
It returns the present state of the data even if the transaction is not committed. So, we may get dirty data. The advantage is, SQL Server will not take any lock and the query would be faster.

Read Committed:
It returns the consistent and committed data. But, it takes shared lock on the data, and that takes little more time than the above.

In Oracle, there is no Read Uncommitted, and there is only Read Committed. Read Uncommitted is more faster than Read Committed. This person was boasting of Microsoft that, it has one feature which Oracle does not have. But, the truth is, Oracle's Read Committed does not take any lock on the data. So, there is no need to use read uncommitted which gives dirty data, when we are getting accurate data without taking any lock.

If a free software supporter is going to boast of some great UI in some open source software, then the Microsoft supporter most probably laugh at that. Microsoft has been very good in developing cool and rich UI since the very beginning. Open source softwares and Oracle (including Sun) have been very good in most of the Non UI softwares. If anyone goes to the other territory, then most probably, they would defame their product.

In the above example only, if we see the scalability or performance of the databases, Oracle is much superior than SQL Server. But, if we see the IDEs or other tools of SQL Server that assist the developer, they beat the tools of Oracle.

If you think there was a mistake in the first line of this post, please read that in binary.

Thursday, April 08, 2010

Doing Less Work and Less Quality Work

For a long time, I had a doubt. I know many people, who are very talented and they tried their best and reached a very high position in the society. After few years, they have resigned to their positions saying that, they could not do what they wanted to do.

I know that, if a person is in a position with some power and responsibility, it is very rare that, he/she can use the full power. Most of the time, that person's superiors control those powers directly or indirectly. For example, a Chief Minister cannot do whatever he/she wants to do in the state, eventhough he/she is the head of the state. The party/alliances/other political powers control most of them. A Chief Minister may be able to do on his/her own what a minister can do, and may not be more than that. Similarly, a minister may be able to do what a collector can do and so on.

My doubt was, they are in a good position and they can completely utilize their subordinates powers. Then, why do they resign? Why cannot they do in that (less) capacity only?

Recently, I realized that, it is very subjective. P.V.R.K.Prasad, Retired IAS officer and Secretary to P.V.Narasimha Rao, gave brief detail on this in his book Asalem Jarigindante. His batchmate in IAS, Abhash Chatterjee was very talented, and he was posted in Bihar. After 20 years in service, he told Prasad that he would be leaving the services. Prasad asked him why he was leaving, when he could do something to the society by continuing in the services. Chatterjee told him that, since all the politicians are not at all giving freedom, he was losing his creativity and also the enthusiasm to work, and is leaving. Prasad also mentioned that, Aruna Rai and Dr.Jayaprakash Narayan also left because of the similar reasons.

At that time, I realized that even I faced the same problem. If someone has some capability, and if they work much below to their capacity, then gradually, they lose their talent. It may take quite some time for them to regain it even after getting full power. Some times, if they take different approach, they may be able to do much better than what they could have done by continuing in the same position. Of course, it is very subjective, and it varies a lot from time to time. But, I am sure, continuing in a not so good position for 15 years will have negative impact for many people.

Monday, April 05, 2010

Variation in Giving Importance By Companies W.R.T. Employees

I know two companies A and B. They have few basic differences.

Company A gives maximum importance to their employees. The company thinks that, his employees know a lot, and outside people do not have that much knowledge. When they hire, they always give less salary/designation to outside employees when compared to the people of the same experience in the company.

Company B gives equal importance to everyone. They decide the salary/designation based on their perceived value that company gets from the employee. If the candidate performs extra ordinarily in the interview, the new hires may get better salary/designation than the people who are in the company with the same experience.

Initially, I thought company A is arrogant, and all companies should be like company B. Later on, I realized that, it may not be correct.

I have seen employees of B, who were paid less than many other people who were hired with the same experience. The reason they give is, this employee has not been performing well, and the new person has good knowledge. So, they were offering better salary/designation than the current employee. But, if they conduct the interview and ask the same questions to both, they would perform almost equally. For the new hire, they can test only for 4-5 hours, and they try to get the information only on the most important points. Where as for the existing employee, they have been testing for a long time, so, they know all the negative points, and most of the time, the negative points dominate positive points.

I heard many employees of Company B saying that, since they are not getting promotion, they would leave the company, and after 2 years, they will come back at two levels higher. If the company is going to give 2 levels higher, after working outside the company for 2 years, there is nothing more that destroys the company. They are encouraging the people to move out, and come back after some time. This is not good for the company.

That's when I understood the advantages of Company A's policies eventhough from outside, it looks like they are arrogant. They always encourage people to stay longer in the company. If the employee stays for long time in the company, there is more advantage to the company.

Friday, April 02, 2010

Who is to be blamed For Writing Crappy Code?

For any typical development of any feature, the following is the general process.

  • High level Design
  • Rough Implementation of the main line scenario
  • Manual Testing of the main line scenario
  • Making the code clean
  • Writing automation testcases for the main line scenario
  • Rough Implementation of all the other scenarios
  • Manual Testing of all the other scenarios
  • Making the code clean
  • Writing automation testcases for all the other scenarios.
  • Verifying the entire functionality and code for performance, security, integration and functionality miss.
  • Implementation of the above
  • Manual testing
  • Automation testing

For any reasonably big feature this is the general process. Few steps may take less time and few may take more time. But, all are important. If a developer gives an estimate of 10 days for any functionality, then it is possible for the developer to declare code complete after the first 3 steps and may be in 2-3 days. But, that will have bugs, misses in the functionality, performance and security problems etc.

Let's take a hypothetical situation of a developer and a hypothetical story.

The developer is given only 25% of the time to finish the functionality. So, he could do only the first three steps in the above process, and delivered the code. The test team identified few bugs in that in functionality, performance and security. Even to fix the bugs, the management decided the time, and developer was not asked for the estimations. So, the developer had time just to fix the given bug and nothing else.

Since the developer knew that, the product is not in a clean state, and he suggested architectural changes to improve the product. But, nobody listened to him. The management has changed, and even the new management did not approve of changing the architecture of the product.

Whenever the developer is working on any functionality, he used to spend one or two hours extra, and started cleaning up existing code. Once the developer got plenty of time, since nothing was assigned to him. He started cleaning up few main classes. Other team members saw this and raised this issue in a meeting. All non-developers unanimously decided that, the developer should not change the code like that. If he wants to change anything in the code, he has to write a detailed design doc first, and present to everyone in the team. Once everyone approves that, then he can go ahead with the implementation. Till then, he should not change any thing in the code. The developer said, there is nothing major he is changing. Since the code is crappy, he is looking at each method, and cleaning it without modifying any behaviour. There is nothing to write in a design doc for that. But, nobody agreed to his proposal. The developer had to sit idle for few more days, because nothing was assigned to him, and he was not allowed to clean up the code.

After few months, one serious performance issue came up. Another developer looked at the code and found the bottleneck method. That code is very crappy. He rewritten that method in two hours, and the performance is improved by 10 times. The new developer asked the entire team, who wrote that method originally. It was written by the first developer.

The developer who originally wrote that code has to be blamed for writing that much crappy code. It does not matter what were the reasons behind that. In the source control, his name is against that version of the code. So, he only has to be blamed for that. This should highlight in the review process. This much crappy code is not expected from a person, who has so many years of experience.