Engineering
Engineering, 31.12.2019 03:31, chinadoll24

Develop a program that computes the scalar product of two vectors. the program must not accept vectors having different size (in such a case print an error message) for example:

> (scalar-product '# (1 2 3) '#(2 1 1))
7
> (scalar-product '#(1 2 3) '#(1 2 3 4 5))
error: different sizes of vectors!
>

a) write the program in iterative style using the do loop
b) write the program using recursion.

answer
Answers: 1

Other questions on the subject: Engineering

image
Engineering, 03.07.2019 14:10, volleyballfun24
If the thermal strain developed in polyimide film during deposition is given as 0.0044. assume room temperature is kept at 17.3 c, and thermal coefficient of expansion for the film and the substrate are 54 x 10^-6c^-1 and 3.3 x 10^-6c^-1respectively. calculate the deposition temperature.
Answers: 3
image
Engineering, 04.07.2019 18:10, tobyhollingsworth178
Which from the following instrument is commonly used to detect the high pitch butzing sound in bearings? [clo4] a)-digital ultrasonic meter b)-infrared camera c)-spectroscopic d)-vibrometer
Answers: 2
image
Engineering, 04.07.2019 19:10, LadyHolmes67
Apressure vessel with an r/t 20 cannot be treated as thin walled vessel. a)-trune b)- false
Answers: 3
image
Engineering, 04.07.2019 19:10, 592400014353
For a process taking place in a closed system containing gas, the volume and pressure relationship is pvi-constant. -1.5 bar, the process starts with initial conditions, pi = =0.03 m3 and ends with final volume, v2-0.05 m3 determine the work done by the gas.
Answers: 2
Do you know the correct answer?
Develop a program that computes the scalar product of two vectors. the program must not accept vecto...

Questions in other subjects:

Konu
Social Studies, 27.11.2020 22:20
Konu
Social Studies, 27.11.2020 22:20