I want to build a loop, that will compare two values every time and return the bigger one. For example, if say k=5 and b=6 then k>b is false and it should set k equal to 6, and then if my next number is for example, smaller than 6 then it should not change the value of k and should continue comparing k with other values
MATLAB: Finding maximum value in a sequence
matlab matrix loop
Best Answer