mardi 2 février 2021

Can I control exactly what a function returns (i.e. rand()) when debugging?

Say I have the following lines of code:

int a = rand();
int b = rand();
int c = rand(); 

Is there any way, when debugging, to make it so that 'rand()' will return, say, 1, then 2, then 3 to variables a, b, and c, respectively?

If not (which I assume is likely the case), is there an easy Ctrl-F replacement method where I can hardcode in these values when debugging?




Aucun commentaire:

Enregistrer un commentaire