(Aug-19-2019, 07:03 AM)everafter Wrote: as per my understandingexactly the opposite - in this case it will execute lines 3-4
if (k>0)then it should jump on else statement
on line 10 you call your function and initial value of k is 6
you can visualise step-by-step execution here
If you can't explain it to a six year old, you don't understand it yourself, Albert Einstein
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs
How to Ask Questions The Smart Way: link and another link
Create MCV example
Debug small programs