Bad Battery or bad alternator?

I have a honda accord 1999 i bought it of my uncle he said alternator is brand new and the batter is also new not even a year he bought it he said but when i turn it on it makes the clicking noise when a battery is dead I was using it before driving around to see how it runs but then i turned it off and try to turn it on again and it just would not turn on what's the problem?

Testing the individual components is the only way to be sure. Remove the battery, and take it to your local auto parts store (O'Reilly, Autozone, etc). Have them charge the battery and perform a load test to ensure it is good. If it's good, take it back home, reinstall it, and the car should start regardless of alternator functionality. Drive the car up to the parts store and have them check the alternator output. But keep in mind that if the alternator isn't charging the battery, the car may only run for about half an hour before dying, so be quick. If the alternator isn't charging the battery, remove it and have the parts store perform a bench test to rule out wiring and connection issues in the vehicle. Battery problems can make it seems like a problem with the alternator, and vice versa, so don't waste your money replacing good components. Most, if not all parts stores will perform these tests for free, so take advantage of them.

PS - If the battery tests good and the car still won't start, check your battery terminals for good clean connection, then turn your attention to the starter and starter relay. Hope this helps!

Use a digital multimeter set to the 20 volt DC scale to check the condition of the battery. It will read 12.6 volts at a full charge, 12.4 at a 75% charge, 12.2 volts at 50% charge, 12 volts at 25% charge, and below 12 volts the battery is, for all practical purposes, dead. If the battery is fully charged then remove the cables at the battery and clean the posts and cable connections. If that does not work then you may have a blown main fuse. If the battery is dead suspect the alternator is defective. You can check it's
condition by jump starting the car and with the engine at idle you should read from 13.5 to 15.5 volts at the battery. Any less and the alternator is defective.

Is your serpentine belt worn old?
Could also be your starter solenoid.