1、shell 的AWK命令调用方法
2、shell的sed命令调用方法
3、git指令的vebase/tree/charrity
4、CP/DCP区别
5、try catch exception捕捉错误,else作用是什么?
6、Python list如何增加item.
7、编写如下python 对二维list进行升序排列的函数。
Question:
Sort,given2 darray in order of ascending.Flatten the 2Darray, and sort it such that first sort
order is the first number, second sort order is the second number
‘’’
input_arr = [
[‘55-29’, ‘55-32’, ‘62-3’, ‘84-38’],
[‘36-84’, ‘23-53’, ‘22-58’, ‘48-15’],
[‘72-80’, ‘48-6’, ‘11-86’, ‘73-23’],
[‘93-51’, ‘55-11’, ‘93-49’, ‘72-10’],
[‘93-66’, ‘71-32’, ‘16-75’, ‘55-9’],
]
ouput_arr = [‘11-86’, ‘16-75’, ‘22-58’, ‘23-53’, ‘36-84’, ‘48-6’, ‘48-15’, ‘55-9’, ‘55-11’, ‘55-29’, ‘55-32’, ‘62-3’, ‘71-32’, ‘72-10’, ‘72-80’, ‘73-23’, ‘84-38’, ‘93-49’, ‘93-51’, ‘93-66’]
input_arr1= [ ‘55-29’, ‘55-32’, ‘62-3’, ‘84-38’,‘36-84’, ‘23-53’, ‘22-58’, ‘48-15’,‘72-80’, ‘48-6’, ‘11-86’, ‘73-23’,‘93-51’, ‘55-11’, ‘93-49’, ‘72-10’,‘93-66’, ‘71-32’, ‘16-75’, ‘55-9’]
def sort_2d_array(input_arr=input_arr) -> list:
#TODO
pass