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而言,任务想获得的是互斥锁.任务间通信的 ...
随机推荐
- js拼接url以及为html某标签属性赋值
记录 js拼接url 比如有些时候我们需要为某按钮实现跳转,可以利用下面的方式做到: function ReturnIndex() { var rex = RegExp("tools&quo ...
- 阿里巴巴 Java 开发手册 (五) 集合处理
1. [强制]关于 hashCode 和 equals 的处理,遵循如下规则: 1) 只要重写 equals,就必须重写 hashCode. 2) 因为 Set 存储的是不重复的对象,依据 hashC ...
- Linux生产环境上,最常用的一套“AWK“技巧【转】
最有用系列: <Linux生产环境上,最常用的一套“vim“技巧> <Linux生产环境上,最常用的一套“Sed“技巧> <Linux生产环境上,最常用的一套“AWK“技 ...
- [转]Go语言string,int,int64 ,float之间类型转换方法
1 正文 (1)int转string s := strconv.Itoa(i) 等价于s := strconv.FormatInt(int64(i), 10) (2)int64转string i := ...
- Fiddler-修改请求的上行参数
方法一:对所有的请求打断点 1.rules->automatic Breakpoints->Befor Requests 2.点击选择需要修改的请求 3.选择右侧请求区域的 Inspect ...
- Spring Boot整合Druid配置多数据源
Druid是阿里开发的数据库连接池,功能强大,号称Java语言中最好的数据库连接池.本文主要介绍Srping Boot下用Druid配置多个数据源,demo环境为:Spring Boot 2.1.4. ...
- selenium自学笔记---下拉框定位元素select
下拉框1.先定位select 然后在定位option city = driver.find_element_by_id("selCities_0") city.find_eleme ...
- MongoDB 设置参数
服务器配置文件分析 bin目录下的mongod.cfg是服务器的配置文件,文件中主要的配置参数: 1.数据库文件的存放位置 2.服务器日志文件的存放位置 3.默认的IP地址.端口号 设置密码 默认情况 ...
- mysql DCL数据控制语言
-- 维护性操作 都是在cmd下操作的连接数据库: 本机:mysql [-h localhost] -u account -p 远程:mysql [-h remote_ ...
- IDEA修改选取单词颜色和搜索结果的颜色
一.修改选取单词颜色 下图所示,选取Father后背景为淡蓝色,其它相同单词背景为灰色,根本看不清楚 修改配置 1.修改选取文本背景色为78C9FF 2.修改相同文本背景色为78C9FF,包括iden ...