In both cases there are more than one possible function sutisfying given data.
1. If
then (see attached diagram for details) you can build infinetely many functions. From the diagram you can see two graphs: first - blue graph, second - red graph. Translating their maximum and minimum left and right you can obtain another function that satisfies the conditions above.
2. If
then you can also build infinetely many functions. From the diagram you can see two graphs: first - blue graph, second - red graph. Translating their minimum left and right you can obtain another function that satisfies the conditions above.
Note, that these examples are not unique, you can draw a lot of different graphs of the functions.
Answer: yes, there are more than one possible function