input: Write a function to parse the given URL and print out the protocol, domain name, and path using Python. The function should take a single string argument representing the URL and use the `urllib.parse` module to parse the URL. Return the protocol, domain name, and path as a tuple of strings.
  
  assert url_parser('https://www.example.com/path/to/file') == ('https', 'www.example.com', '/path/to/file')
  assert url_parser('http://another.domain.com/another/path') == ('http', 'another.domain.com', '/another/path')
  assert url_parser('ftp://example.com/folder/file.txt') == ('ftp', 'example.com', '/folder/file.txt')
  assert url_parser('https://sub.domain.co.uk/section/page') == ('https', 'sub.domain.co.uk', '/section/page')
  assert url_parser('http://localhost:8080/index') == ('http', 'localhost:8080', '/index')
output: def url_parser(url):
      from urllib.parse import urlparse
      parsed_url = urlparse(url)
      return (parsed_url.scheme, parsed_url.netloc, parsed_url.path)