Difference between revisions of "Is Strictly Ascending Assignment"

From CSE425S Wiki
Jump to navigation Jump to search
(Created page with "=Code to Implement= {{SMLToImplement|is_strictly_ascending|is_strictly_ascending|warmup_is_strictly_ascending}} ==is_strictly_ascending== Write a function fun is_strictly_...")
 
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
 
=Code to Implement=
 
=Code to Implement=
  
{{SMLToImplement|is_strictly_ascending|is_strictly_ascending|warmup_is_strictly_ascending}}
+
{{SMLToImplement|is_strictly_ascending_fun|is_strictly_ascending|warmup_is_strictly_ascending}}
  
 
==is_strictly_ascending==
 
==is_strictly_ascending==
Line 11: Line 11:
  
 
=Test=
 
=Test=
{{SMLUnitTest|is_strictly_ascending|warmup_is_strictly_ascending}}
+
{{SMLUnitTesting|run_is_strictly_ascending_testing|warmup_is_strictly_ascending_fun}}

Latest revision as of 05:41, 7 September 2022

Code to Implement

file: src/main/sml/warmup_is_strictly_ascending/is_strictly_ascending_fun.sml Smlnj-logo.png
functions: is_strictly_ascending

is_strictly_ascending

Write a function

fun is_strictly_ascending(xs : int list) : bool

which returns true if every value in xs is strictly less than all of the values which follow it.

Test

source folder: src/test/sml/warmup_is_strictly_ascending_fun
how to run with CM.make verbosity off: sml -Ccm.verbose=false run_is_strictly_ascending_testing.sml
how to run with CM.make verbosity on: sml run_is_strictly_ascending_testing.sml

note: ensure that you have removed all printing to receive credit for any assignment.

SML Error Messages