Cadence Design Systems interview question

second round another form of fibonacci programming question, after coding, analyze the time complexity C pit fall question returning the address of local variable