The two of the oldest man need cheers
At a company dinner, the drinking rule was that two colleagues of similar age clinked glasses of wine.
Each meal was attended by a different number of people, who listed their ages in an irregular order. Finally, the two oldest people clinked glasses and drink for the first time.
Write a function that takes an array of the ages of the people at the table, returns the ages of the two people who clinked their glasses for the first time, and returns it in order of smallest to largest.
example:
[1,5,87,45,8,8] -> [45,87]
[6,5,83,5,3,18] -> [18,83]
have fun~
The two of the oldest man need cheers的更多相关文章
- kinect (oldest one) (libfreenect with py_kinect) on linux ubuntu14.04 x64
freenect libs Where is the resource? Here :P : https://github.com/OpenKinect/libfreenect To make sur ...
- The Sorrows of Young Werther
The Sorrows of Young Werther J.W. von Goethe Thomas Carlyle and R.D. Boylan Edited by Nathen Haskell ...
- python瓦登尔湖词频统计
#瓦登尔湖词频统计: import string path = 'D:/python3/Walden.txt' with open(path,'r',encoding= 'utf-8') as tex ...
- NCE2
1.A private conversation Last week I went to the theatre. I had a very good seat. The play was very ...
- Download Visual Studio
Welcome to a new way to install Visual Studio! In our newest version, we've made it easier for you t ...
- A1
It’s surprising what you can find at the end of your garden. Wild flowers... and even smaller yet, i ...
- BumpMapping [转]
http://fabiensanglard.net/bumpMapping/index.php Fabien Sanglard's Website Home About FAQ Email Rss T ...
- SDWebImage源码解读之SDWebImageCache(下)
第六篇 前言 我们在SDWebImageCache(上)中了解了这个缓存类大概的功能是什么?那么接下来就要看看这些功能是如何实现的? 再次强调,不管是图片的缓存还是其他各种不同形式的缓存,在原理上都极 ...
- ucos实时操作系统学习笔记——任务间通信(队列)
ucos操作系统中的queue机制同样使用了event机制来实现,其实和前面的sem,mutex实现类似,所不同的是对sem而言,任务想获得信号量,对mutex而言,任务想获得的是互斥锁.任务间通信的 ...
随机推荐
- pytest_03_pycharm运行pytest (转:上海悠悠)
前言 上一篇pytest文档2-用例运行规则已经介绍了如何在cmd执行pytest用例,平常我们写代码在pycharm比较多 写完用例之后,需要调试看看,是不是能正常运行,如果每次跑去cmd执行,太麻 ...
- jquery跨js文件调用函数示例
var common_func; (function() { common_func = { load_hot_data: function(AreaCode) { var hot_html = &q ...
- 【转载】C#中Convert.ToDouble方法将字符串转换为double类型
在C#编程过程中,可以使用Convert.ToDouble方法将字符串或者其他可转换为数字的对象变量转换为double类型,Convert.ToDouble方法有多个重载方法,最常使用的一个方法将字符 ...
- js正则表达式(七)
一.正则表达式对象的创建方法一:使用构造函数的形式: var pattern = new RegExp('正则表达式','修饰符'); var pattern = new RegExp('hello' ...
- python多任务的实现:线程,进程,协程
什么叫“多任务”呢?简单地说,就是操作系统可以同时运行多个任务.打个比方,你一边在用浏览器上网,一边在听MP3,一边在用Word赶作业,这就是多任务,至少同时有3个任务正在运行.还有很多任务悄悄地在后 ...
- ar 解压一个.a文件报错: xxx.a is a fat file (use libtool(1) or lipo(1) and ar(1) on it)
Linux 使用终端指令 ar x /Users/apple/Desktop/libWC_LIB_SDKT.a解压一个文件 报错如图所示: 是因为该.a文件包含了多个cpu架构,比如armv7,ar ...
- S/4HANA Service Management和SAP Field Service Management的集成
经常有朋友提出这样的问题:"SAP Business Suite里的CRM的Service模块已经通过Addon的方式迁移到了S/4HANA上,并且SAP之前又收购了一家专门做Service ...
- java-springCloud环境配置
SpringCloud注解和配置以及pom依赖说明 https://www.cnblogs.com/zhuwenjoyce/p/9663324.html https://blog.csdn.net/s ...
- scrapy 爬虫中间件 deepth深度
源码 class DepthMiddleware(object): def __init__(self, maxdepth, stats, verbose_stats=False, prio=1): ...
- (二)分布式数据库tidb-事务
tidb既然是分布式数据库,所以它的事务应该可其它数据库事务有着不同的区别.我们来了解下tidb的数据库事务. (一)事物 1.几种数据库的默认隔离级别: tidb是乐观锁 (二)事务语句 TiDB ...