CSE 109 Progam 6 Due 9 PM Monday 7 April 2008 Late collections 9 PM 8,9 April 2008 Modify program 5 so that it generates sml code that corresponds to the given YAPL program, provided the given YAPL program is syntactically correct. The input to program 6 should be a file consisting of YAPL language statements, finishing with "end", the "end" possibly followed by text that should be appended after the 'END' in the corresponding sml program. Program 6 should have two output files, the first containing the results of the parse, and the second the sml code, followed by 'END'. If the input file has text after "end" then the text should simply be appended to the sml code in the second file after the 'END'. Thus, the second output file should be suitable as an input file to sml. For example, below I list a YAPL program and the sml code that yapl generated for that program (NOTA BENE: THE SML CODE THAT YOUR SOLUTION TO p6 GENERATES NEED NOT BE IDENTICAL TO THIS CODE, BUT IT MUST LEAD TO THE SAME OUTPUT WHEN THE CODE IS RUN IN SML.) read x goto 100 if x < 0 write x 100 halt end 5 10019 [0] 20017 [1] 20019 [2] 21999 [3] 20017 [4] 21998 [5] 20999 [6] 31998 [7] 41011 [8] 20018 [9] 40012 [10] 20017 [11] 42016 [12] 20019 [13] 21999 [14] 11999 [15] 43000 [16] 0 [17] 1 [18] 0 [19] END 5 To submit your assignment, create a subdirectory of /cse109.081 called p6 (that is, from your root directory cse109.081/p6) for doing your work. Finally, indicate you wish the assignment to be collected by executing the unix command "touch DONE", which will create a file of 0 bytes named DONE. Then all files in the subdirectory p6 (but not in subdirectories of the subdirectory p6) will be collected. I will test your program using your Makefile. Some of the test files for p6 have been stored in /proj/csc109/p6. As always I warn you to heed my admonition that you not unfairly collaborate. To understand what it means to unfairly collaborate read the course syllabus.