ronreiter / interactive-tutorials

Interactive Tutorials
Apache License 2.0
4.01k stars 2.55k forks source link

learn-c: Correct usage definition of static variables #752

Closed santoshx closed 3 months ago

francescoalterio commented 9 months ago

Perfect change, everything correct.

ppisecky commented 3 months ago

The pull request is broadly correct - you cannot access a static c variable from anywhere in the file. It just gets retained in memory but you can't access it outside of its original scope.