You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
463 B
17 lines
463 B
'''
|
|
Author: SJ2050
|
|
Date: 2021-10-29 19:23:02
|
|
LastEditTime: 2021-10-29 22:45:38
|
|
Version: v0.0.1
|
|
Description: Solution for homework1_6.
|
|
Copyright © 2021 SJ2050
|
|
'''
|
|
import numpy as np
|
|
|
|
if __name__ == '__main__':
|
|
random_mat = np.random.rand(10, 10)
|
|
max_one = np.max(random_mat)
|
|
min_one = np.min(random_mat)
|
|
|
|
print('随机产生的矩阵如下:\n', random_mat)
|
|
print(f'最大值元素为: {max_one}, 最小值元素为: {min_one}') |