Joomla is open source software under the GPL license. One of the benefits of open source software is that you can (and are allowed to) read and change the source code.
Therefore it's very easy to make small changes in Joomla's core code. But loosing those changes by just upgrading is even easier!
In this presentation Peter will show you how you can make changes in Joomla and 3rd party extensions without using core hacks: