Ideally? You don't need to buy anything at all.
You should ask your GM ahead of time if there's anything they specifically want you to bring, but here is the important thing to remember about the books, or any gaming kit really:
It can and should all be shared by players and GM alike
I can think of very few items in a gaming system that cannot be borrowed from another person or easily produced for free. Dice can be lent (most experienced players will have a collection anyway), books can be borrowed (as a beginner, you may want someone else to help you make your character anyway), and character sheets can be printed off the web or simply fabricated with paper and pencil/pen. The Game Master is usually the one responsible for bringing books to a gaming session, so unless you plan on being the Game Master right away (not recommended—experience playing is the best way to learn good game master practice), you can count on the game master for your gaming tools.
Now don't feel like if you've bought a few 3.5e books already that you need to return those books right away. It's easier to make your own character as you see fit when you've got your own copy of the rules. But, don't feel like you must have any particular book to play a game either—a good Game Master will provide for new players, and good players will help new players along.