Build a REST URL
Given an HTTP method, a resource name, and (optionally) an ID, construct the correct RESTful URL path following standard REST conventions.
Approach: if an ID is given, the path is METHOD /resource/id; if not (the id is the literal text None), the path is just METHOD /resource.
Input: Three lines: the HTTP method, the resource name, and the id (or the literal text None if there isn't one).
Output: One line: the constructed REST path, e.g. GET /students/5.
GET students 5
GET /students/5
- method is one of GET, POST, PUT, PATCH, DELETE.
Hint 1
A GET on a whole collection (like listing all students) has no id — just METHOD /resource.
Hint 2
A GET/PUT/DELETE on ONE specific item includes its id — METHOD /resource/id.
Hint 3
Check resource_id == "None" to decide which format to print.
REST paths follow a simple pattern: acting on a specific resource (an id was given) appends /id after the resource name; acting on the whole collection (creating a new one, or listing them all) doesn't. Checking whether resource_id is the literal "None" decides which of the two formats to print.