❔ How is my counter not incrementing?

4 Replies
phaseshift
phaseshift2y ago
count is a local variable
KeezyEnraged
KeezyEnragedOP2y ago
Ahhhh So it has to be globalized
phaseshift
phaseshift2y ago
if you call numberOfSteps from itself, you get a new stack, a new version of 'count' or rather pass that in to the method as another param
Accord
Accord2y ago
Was this issue resolved? If so, run /close - otherwise I will mark this as stale and this post will be archived until there is new activity.
Want results from more Discord servers?
Add your server