Car driving good then loses power.
Is the Check Engine Light lit-up?
Or–much worse–is that light flashing/blinking?
Is that a question?
More information would help.
Or is it haiku?
Loses power - or RPMs go up when you push the gas pedal, without the acceleration you’d expect?
You really need to provide some useful information and which might help to narrow it down from a 100 things to 20 or so.
IF the CEL is not on, not flashing, and there are no codes present then one might suspect a failing fuel pump. Another often overlooked problem which can cause this are scaled over battery terminals. Both of those are just WAGs. Battery terminals are easily checked and cleaned.
How long foes it take to change alternator
A good mechanic can do it in a couple of hours , An inexperienced do it yourself person a whole weekend.
Do you actually know you need an alternator ?
Details are as murky as a London fog.
As Pyrolord mentioned, this is a quantum leap from asking for diagnostic help (while providing almost no important details) to the OP’s apparent decision to replace the alternator–especially in light of her failure to respond to the following questions:
What we have here is
failure to communicate
(another haiku!)
First things first.
Electrical power or motive power?