The Java Specialists' Newsletter
Issue 069b2003-05-02 Category: Performance Java version:
Subscribe RSS Feed

Results of last survey
by Dr. Heinz M. Kabutz

This is a quick follow-up to let you know the score of the survey from the last newsletter. In the newsletter I mentioned that i += n is the same as i = (type_of_i)(i + n). A number of readers were surprised that I should mention such an obvious bit of information in an advanced Java newsletter. They were in the minority. Only 32 of the responses indicated that they already knew that information, and a staggering 174 readers responded that they did not know. That comes to only 15.53% of Java Specialists knowing about this. Imagine how few Java beginners know about this?

The quote was attributed to Ralph Waldo Emerson.

Beno Patrik from CLEVERLANCE wrote, suggesting that we could add the cast from int to double to the formula. That would mean that i += n is the same as i = (type_of_i)((type_of_n)i + n), if n is of higher precision than i. I did realise that when I was writing the newsletter, but did not want to muddy the waters. That is a typical upcast that we would expect. The one that I mentioned was a downcast, losing precision, and that we would not expect without a compiler error.

Yesterday, Andrew Righthouse and I spent the public holiday updating the "Feeding the 5000" webpage. We've added new pictures, and Andrew explained a bit more about what the people of the townships experience daily. South Africa is a concentrated example of the sufferings of this world. Less than 10km away from where I live is poverty where people live below the breadline. Visitors who come to South Africa are disturbed about this; that some should live in big houses, drive fancy cars, and others in the same town would be starving. It is dreadful, a legacy of an evil system that will take years to right. Yet the contrast that is so evident in South Africa is a picture of the suffering of the whole world. We have rich countries and poor countries. They are perhaps separated by 1000's of kilometers, but that does not make the poor nations disappear. They are still there, whether you like it or not.


Performance Articles Related Java Course

Would you like to receive our monthly Java newsletter, with lots of interesting tips and tricks that will make you a better Java programmer?