Answer:
The function in Python is as follows:
def greetings(details):
    details = details.split(' ')
    print('Hello, '+details[0]+'!, I also enjoy '+details[2])
Explanation:
This defines the function
def greetings(details):
This splits the input string by space
    details = details.split(' ')
This prints the required output
    print('Hello, '+details[0]+'!, I also enjoy '+details[2])
After splitting, the string at index 0 represents the name while the string at index 2 represents the hobby