Does gtx 770 work on this computer?

Assuming you have an adequate power supply it will work. However the CPU is old and slow, so you won't get much performance out of the 770. If you play older, less demanding games then it won't matter of course. If that's the case though you could buy a less expensive videocard. For instance, a used GTX 650 Ti or 750 Ti would probably make more sense.