数学实验作业

max min sum

You are now following this Submission

clc,clear
SZ = [1,2,3,4,5;
6,7,8,9,10;
11,12,13,14,15;
16,17,18,19,20;
21,22,23,24,25];
max=-10^99;min = 10^99;sum = 0;
for i =1:1:5
for j = 1:1:5
bb = SZ(i,j);
if i+j<5&&j>=i
sum =bb+sum;
end
if bb >max
max = bb;
H = i;
L = j;
end
if bb < min
min = bb;
h = i;
l = j;
end
end
end
max
H
L
min
h
l
sum
clc,clear
x = input('x = ');
y = input('y = ');
X = x;
Y = y;
for i = 1:99999999999
g = floor(x/y);
g = x-y*g;
x = y;
y = g;
if y == 0
break
end
G = g;
end
G
B = X*Y/G

Cite As

亮 (2026). 数学实验作业 (https://se.mathworks.com/matlabcentral/fileexchange/117750), MATLAB Central File Exchange. Retrieved .

Tags

Add Tags

Add the first tag.

General Information

MATLAB Release Compatibility

  • Compatible with any release

Platform Compatibility

  • Windows
  • macOS
  • Linux
Version Published Release Notes Action
1.0.0