how split text in python by space or newline with regex

Solutions on MaxInterview for how split text in python by space or newline with regex by the best coders in the world