A computational method for the approximation of functions in the space L[0, 1]