//for the minimum
The function GetMinInArray (A: an array of Integer) : Integer;
Var I: Integer;
TmpMin: Integer;
The begin
TmpMin:=A, [0].
For I:=low to High (A) (A) do
The begin
If A [I]
Result:=tmpMin;
end;
CodePudding user response:
Correct under the above function that returns the type doubleThe function GetMinInArray (A: an array of double) : double;
Var I: Integer;
TmpMin: double;
The begin
TmpMin:=A, [0].
For I:=low to High (A) (A) do
The begin
If A [I]
Result:=tmpMin;
end;
CodePudding user response:
The function GetMinInArray (A: an array of double) : double;
Var I: Integer;
TmpMin: double;
The begin
TmpMin:=A, [0].
For I:=low to High (A) (A) do
The begin
If (A [I] <> 0) and (A [I]end;
Result:=tmpMin;
end;
The function GetMinInArray (A: an array of double) : double;
Var I: Integer;
TmpMin: double;
The begin
TmpMin:=A, [0].
For I:=low to High (A) (A) do
The begin
If (A [I] & gt; 0) and (A [I]end;
Result:=tmpMin;
end;
CodePudding user response:
LZ is too fixed mind, don't turn the,Even you know how to use more sorting method for screening the minimum, that when you compare condition does not have to add a not 0
CodePudding user response:
CodePudding user response:
0.8 smaller than 0?