How to call a function in a function in python
<p>I have a problem about function in python, and i'm pretty new in programming, so please giving your examples in the simplest way, thanks</p>

<p>I want to call a function in a function like this:</p>

<pre><code>def func1 (a):
    b = a + 1
    def func2():
       c = b*3
       print c
    def func3():
       c = b/5
       print c

func1(5).func2()
</code></pre>

<p>how can i call func2 inside func1 or func3 inside func1 ? and yes, i do need func1, func2 and func3, i don't want to use class</p>

<p>Although you don't really need new functions to do such simple tasks, calling functions in another function would be something like this:</p>

<pre><code>def func2(b):
    return b*3

def func3(b):
    return b/5

def func1(a):
    b = a + 1
    c = func2(b)
    print c
    c = func3(b)
    print c
</code></pre>

<p>and finally call your function with an input, 5 for example:</p>

<pre><code>func1(5)
</code></pre>

python function nested