As used here, there&#x27;s two ways you can do this in C.<p>Since the variable in question is only used in one function, you could declare the variable static to that function.  It takes some care to make this reentrant, but that&#x27;s possibly the case in lisp as well.<p>To share between multiple top-level functions, you can only limit scope to the individual file.<p>The bigger thing C can&#x27;t do that lisp can here is defining new functions in arbitrary places.  In C variants where you can define local functions, you can indeed capture variables in local scope.  And within a function, you can limit scope by creating a new block:<p><pre><code>    int test() {
        int foo = 7;

        {
            int foo = 9;
        }

        return foo; &#x2F;&#x2F; returns 7
    }

</code></pre>
Even in those C variants, you can&#x27;t place a new function in global scope from within a function.