Write the definition of a function half which recieves a variable containing an integer as a parameter, and returns another variable containing an integer, whose value is closest to half that of the parameter. (Use integer division!)
function half(x) which has return type integer and accept an integer type parameter 'x' and return the an integer value in variable 'a' which is closest to half that of the parameter 'x'.