How to resolve the algorithm Take notes on the command line step by step in the Phix programming language

Published on 12 May 2024 09:40 PM

How to resolve the algorithm Take notes on the command line step by step in the Phix programming language

Table of Contents

Problem Statement

Invoking NOTES without commandline arguments displays the current contents of the local NOTES.TXT if it exists. If NOTES has arguments, the current date and time are appended to the local NOTES.TXT followed by a newline. Then all the arguments, joined with spaces, prepended with a tab, and appended with a trailing newline, are written to NOTES.TXT. If NOTES.TXT doesn't already exist in the current directory then a new NOTES.TXT file should be created.

Let's start with the solution: