Today, when I am coding, this question occurred to me.
When we want to define and use a variable, should we make its scope bigger or not? Especially when the same variable would be used in several block statements, but there isn't any relation between these block statements with this variable. So which is better? Let the variable outside all block statements, or define in each block statement. Give out an example like this:

FIRST:

```
int vl_ret = 0;
int b = 1;
int c = 1;

if (b == 1)
{
    vl_ret = do_something();

    if (vl_ret == 1)
    {
        printf("1\n");
    }
    else
    {
        printf("0\n");
    }
}

if (c == 1)
{
    vl_ret = do_something();

    if (vl_ret == 1)
    {
        printf("1\n");
    }
    else
    {
        printf("0\n");
    }
}

```

or
SECOND:

```
int b = 1;
int c = 1;

if (b == 1)
{
    iny vl_ret = do_something();

    if (vl_ret = 1)
    {
        printf("1\n");
    }
    else
    {
        printf("0\n");
    }
}

if (c == 1)
{
    int vl_ret = do_something();

    if (vl_ret = 1)
    {
        printf("1\n");
    }
    else
    {
        printf("0\n");
    }
}

```

because these local variables are allocate from the stack, so it can be very fast, we can ignore the more spent time by allocate form stack in the second method.

I think, the second is better, because I just need this variable in each block statement, if once i don't need it, I can easily modify my code. And in the second method, the code is much clearer. We can see, the variable also will not be influenced by other block statements.