add java solution for RemoveCharacters