Speaking of the apps that come standard with the iPhone, the one that is most applicable is "Memo". As a memorandum for jotting down thoughts, as a tool for drawing hand-drawn illustrations, and as a tool for scanning paper documents, memo apps demonstrate their flexibility.
The memo app automatically saves the notes you create in iCloud or iPhone's internal storage. You don't need to be conscious of saving because it will be updated/overwritten instantly every time you change something, but if you intentionally "delete" it, the story will change.
The deleted memo will be registered in "Recently Deleted Items" and will be managed for the next 30 days. Rather than "deleting" it, it's more like "quarantine" with normal memos, and it's a process similar to "trash" in mail and photo apps. After 30 days, it will be automatically unregistered and completely deleted from iCloud/iPhone storage at the same time, but you can restore it anytime within 30 days.
However, in principle, the memos that can be restored are limited to those created on iCloud or iPhone storage. The memo app can be linked with external services such as Gmail, but if you delete the memo, it will not be registered in "Recently Deleted Items" and will be completely deleted as it is.
To restore a memo from "Recently Deleted Items", tap "Recently Deleted Items" on the folder list screen (upper hierarchy such as "All iCloud" where you usually work), and select the desired memo. Swipe left. If you tap the folder icon that appears and specify the restore destination, the memo can be used as it was.