Combine four function in one