大数据工程师面试考题

1、shell 的AWK命令调用方法
2、shell的sed命令调用方法
3、git指令的rebase/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
‘’’

Example:

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

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值