subject

(* problem 11 [5 points] use map to write a function thattakes an int list and an int and multiplies everyentry in the list by the int. you may define auxiliary functions that arecalled by the times_x function. if you defineauxiliary functions, do not use the samename with any pre-declared function inthis homework. *)(* auxiliary functions (if defined) start here *)(* auxiliary functions (if defined) end here *)let times_x (x: int) (lst: int list) : int list =(* your code start here *)[-1](* your code end here *); ; (* test case: all results should be true *)(times_x 5 [1; 2; 3]) = [5; 10; 15]; ; (times_x 5 []) = []; ; (times_x 2 [1; 2; 3]) = [2; 4; 6]; ; in ocaml

ansver
Answers: 1

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 01:00, shayyy49
How can a broadcast station be received through cable and satellite systems?
Answers: 1
image
Computers and Technology, 23.06.2019 02:30, jaueuxsn
Which component acts as a platform on which application software runs
Answers: 2
image
Computers and Technology, 23.06.2019 08:00, leleee10
Which argument is not a valid filter? does not equal this quarter filter by cell color all of these are valid filter arguments.
Answers: 2
image
Computers and Technology, 23.06.2019 21:30, quintonps12
Which of the following includes the three primary network access technologies? dsl, cable modem, broadband lan, wan, man voip, uc, iptv tcp/ip, ftp, dhcp
Answers: 2
You know the right answer?
(* problem 11 [5 points] use map to write a function thattakes an int list and an int and multiplies...

Questions in other subjects:

Konu
Geography, 05.10.2019 07:00