make function more complex