Function not returning any value

Even if I am explicitly returning some value, it not getting reflected.

Even I was facing the same problem in c++ so I switched to java.

Click here to start solving coding interview questions