Why does BASEURL end with a slash?

  1. Retrofit requires the base URL to end with /
  2. To enable caching
  3. JSONPlaceholder needs it for HTTPS
  4. It makes requests faster
Answer

A) Retrofit requires the base URL to end with /

Retrofit throws an exception if baseUrl does not end with /.

Computer Science MCQ · More Lab: Displaying Data from an API MCQs · Practise