Working Out
The honest way for CJ to reach his maximum stamina level on GTA San Andreas is to go to a gym and work out. While there are cheats to help you attain this level of stamina, they still require you to go to a gym and do some working out. To work out, go into a gym --- marked by a barbell on the map --- and walk up to a piece of equipment. Press triangle and follow whatever command appears. This command is usually along the lines of "tap a button very quickly." To increase stamina, choose a piece of gym equipment that will do so rather than building muscle, like a treadmill or a skipping rope.
When to Work Out
The game will only allow you to work out for a certain amount of time before your muscles become fatigued. At this point you will be unable to work out any further for that day. You can trick the game by going to a gym and working out at 22:00 and working out until 23:00. This should give you time to max yourself out and be unable to continue. Wait until the clock strikes 0:00, at which point the limit will be reset. Continue working out and max yourself out again. This allows you to do twice as much work in one session.
Where to Work Out
After tricking the game by working out from 22:00 to 01:00, you should leave the gym and go to a save point. Saving the game advances time as it mimics the character sleeping. Advance the game time to around 22:00 again and return to the gym to repeat the process. Doing this allows you to build stamina very quickly. In order to maximize the efficacy of the process, choose a gym very near a save point. As you progress in the game, you will find yourself with many save points, but the nearest gym to a save point at the beginning of the game is the gym just to the south of Grove Street. When you own Madd Dogg's mansion, you can work out and save your game in there.
Turbo
If your controller has a turbo button you can use this to help you work out. Enable turbo just after pressing triangle to engage a machine. The turbo button will allow you to simply hold down the button you are required to tap and the controller will do the rest of the work. This is not strictly necessary but will save your fingers from getting tired when you repeat the process.