These are instructions on how to jailbreak your iPhone 3GS on the iOS 5.0 firmware using RedSn0w for Windows. The Mac tutorial is here.
This procedure will cause you to upgrade your baseband potentially ruining your chances for an unlock. Please wait until we have posted a tutorial on how to update to iOS 5 using a custom ipsw if you need an unlock. The jailbreak is also tethered for all devices except the old bootrom iPhone 3GS which means you will need to connect your device to the computer each time you reboot. Finally, it may be prudent to save your SHSH Blobs.