Short Answer
The part after the last slash of a file's URL that is hosted in Google Drive of Google Editors could vary depending if the URL has the purpose to be used to share the file to someone without a Google account, the format to be used to publish the content to the web and include parameters to modify how the content will be published or displayed.
Additional details
Instead of filenames for URL Google Drive and Docs editors uses a "file key" so if the user changes the filename the URL still works.
The "file key" is between the last two slashes [/]. The part after the last slash could vary depending if the URL has the purpose to share the file to someone without a Google account, the format to be used i.e. to publish the content to the web and include parameters to modify how the content will be published or displayed.
/view
for previewing a file in a web browser
/preview
for embedding file in a HTML web page
/edit
for editing a file
/pubhtml
is used when a document, spreadsheet or slide is published to the web.
/pub
is used when a drawing is published as image
Notes
For web site hosting is possible to use filenames in URLs but this require that file are in a public folder.
References
Publish web site content - Drive REST API