+ 1
How to avoid global variables
Refer code below: How to complete this code without changing function signature and not using global variables? https://sololearn.com/compiler-playground/cMmIifMYJoFg/?ref=app P.s. I can use static in function and complete the code. Just checking for other alternative as static solution was ok but more option was asked
2 Réponses
+ 1
Besides global or static you could write it to some permanent storage such as a disk file or Windows registry.
And then there is my other trick of writing to other stack frames 😋
0
Thanks Brian