Code not executing

what is the problem in the code?
it is not giving the desired output.