水。

#include<iostream>
#include<cstdio>
#include<algorithm>
using namespace std; int main()
{
int n,a[];
cin >> n;
for(int i = ;i <= n;i++) cin >> a[i];
sort(a+,a+n+);
int num = ;
for(int i = ;i < n;i++)
{
if(a[i+]-a[i] == ) num++;
}
cout << num << endl;
return ;
}

最新文章

  1. AHCI: Failed to attach drive to Port1 (VERR_GENERAL_FAILURE).
  2. c++模板使用出错情况error LNK2019: unresolved external symbol &quot;public: float __thiscall Compare&lt;float&gt;::min(void)&quot; (?min@?$Compare@M@@QAEMXZ) referenced in function _main
  3. http协议与网页优化泛谈
  4. &lt;转&gt; jsp页面向action传值的方法(最后一种简单)
  5. JS数组(Array)操作汇总
  6. 使用Javascript获得网页中通过GET方法提交的参数
  7. JSP执行过程详解
  8. apk代码的破解
  9. 网易云课堂_程序设计入门-C语言_第四周:循环控制_2念整数
  10. Installutil.exe的位置和路径
  11. sublime 3 增加php开发插件
  12. Erlang调度器细节探析
  13. mysql之聚合函数、group by、having
  14. SpringCloud系列——Feign 服务调用
  15. 为UITextField增加MaxLength特性
  16. vue--组件基础
  17. 转://linux下hugepages理解
  18. Tools:apache部署https服务
  19. python3简单实现微信爬虫
  20. 解决sdk更新时候报错 http://dl-ssl.google.com/android上不去,链接拒绝

热门文章

  1. React实现座位排布组件
  2. 大量SQL的解决方案——sdmap
  3. asp.net core 3.x 模块化开发之HostingStartup
  4. Java BIO NIO 与 AIO
  5. js中排序方法sort() 和 reverse()
  6. PTA - dfs
  7. svn或git 提交文件排除
  8. 一次jvm调优过程
  9. Java入门 - 语言基础 - 06.变量类型
  10. ffifdyop——绕过中一个奇妙的字符串