Write a function that collects integers from the user until


Program 1: Write a function that collects integers from the user until a 0 is encountered and returns them in a list in the order they were input (ML only).

Program 2: Use the functions you wrote for exercises (b) and (c) to write a program to input a 0-ended list of integers, print the list in the order entered, and print the maximum and minimum of the list. For this exercise, use only ML.

Program 3: Write Quick sort for a list of integers (ML only).

Program 4: A Pythagorean triple is a tuple of integers (x, y, z) such that x * x + y * y = z * z.

Write a function with a parameter n to print all Pythagorean triples such that 1 ? x ?y ? z ? n.

Program 5: Write a higher-order function twice that takes as a parameter a function of one argument and returns a function that represents the application of that function to its argument twice. Given the usual definition of the square function, what function is (twice (twice square))?

You need to implement quick sort and provide the code and print the maximum and minimum of the list.

 

Request for Solution File

Ask an Expert for Answer!!
C/C++ Programming: Write a function that collects integers from the user until
Reference No:- TGS0955534

Expected delivery within 24 Hours