MATLAB Answers

## need solution of exercice

Asked by KHAIF HICHEM

### KHAIF HICHEM (view profile)

on 8 Dec 2018
Latest activity Commented on by Walter Roberson

### Walter Roberson (view profile)

on 10 Dec 2018 KHAIF HICHEM

### KHAIF HICHEM (view profile)

on 9 Dec 2018
First exercise involves calculating the sum of two matrices, and the product of two matrices. if, while and for must be used in the code.
Second exercise involves recursive calculation of maximum and minimum of two vectors.)
KHAIF HICHEM

### KHAIF HICHEM (view profile)

on 9 Dec 2018
and in the second exercise i have trying this
function [ vmin ] = mini(vect)
%MINI retourne le minimum d’un vecteur
n = numel(vect); if n == 0, vmin = []; else vmin = vect(1);
for k = 2:n
if vect(k) < vmin, vmin = vect(k);
end
end
end
function [ vmax ] = maxi(vect)
%MAXI retourne le maxiimum d’un vecteur
n = numel(vect);
if n == 0, vmax = []; else vmax = vect(1);
for k = 2:n
if vect(k) > vmax, vmax = vect(k);
end
end
end
but the same problem can't resolve
Walter Roberson

### Walter Roberson (view profile)

on 10 Dec 2018
what problem are you observing ?

Sign in to comment.

## 1 Answer

Answer by KHAIF HICHEM

### KHAIF HICHEM (view profile)

on 9 Dec 2018

Please i need solution

#### 0 Comments

Sign in to comment.