码迷,mamicode.com
首页 >  
搜索关键字:reverse bits    ( 8842个结果
迭代器,sum,max,min、列表排序
1、列表的排序 a = [1,2,3,4,9,7,6,5,8] a.sort() #默认升序排列,对象不变,元素排序 a.sort(reverse=True) #降序排序 import random #打乱,随机排序 random.shuffle(a) 用法二、 a = sorted(a) #默认升 ...
分类:编程语言   时间:2021-04-22 15:55:48    阅读次数:0
L2-011 玩转二叉树 (25 分)
题目大意 给一个二叉树的中序遍历和前序遍历,求其镜像后的层序遍历 类似于 L2-006 树的遍历 (25 分) 建树 镜像就在dfs的时候先输出右子树 再 左子树 #include<bits/stdc++.h> using namespace std; struct node { int l,r; ...
分类:其他好文   时间:2021-04-21 12:12:05    阅读次数:0
FTP服务器配置(记录用)
因业务需要,在centos服务器上配置了FTP服务,做此随笔以记录。配置是以实现多用户多工作目录为目标而配置。 首先在服务器安装ftp: yum install -y vsftpd 2. 一些vsftpd的相关命令: 查看服务状态:systemctl status vsftpd.service 开启 ...
分类:其他好文   时间:2021-04-21 12:03:23    阅读次数:0
PAT 1022 Werewolf PAT顶级
爆搜,按照题意来搜。。。 太难写了,当模拟写的,代码分成了很多块,长度比较难看。。。 #include<bits/stdc++.h> using namespace std; #define ll long long #define fastio ios::sync_with_stdio(false ...
分类:其他好文   时间:2021-04-20 15:37:24    阅读次数:0
数据结构-模板-并查集(路径压缩+按秩合并)
所谓并查集就是将编号为1~n的n个对象划分为不相交集合,在每个集合中,选择其中的某个元素代表所在集合在这个集合中,并查集的操作有初始化,合并,查找。 #include<bits/stdc++.h> using namespace std; #define IOS ios::sync_with_std ...
分类:其他好文   时间:2021-04-20 15:31:02    阅读次数:0
算法-初次尝试-模拟退火
我对模拟退火的初步理解,还没深入了解过。这里只是用模拟退火求函数极值。 题目:https://vjudge.net/problem/HDU-2899 #include<bits/stdc++.h> using namespace std; #define IOS ios::sync_with_std ...
分类:编程语言   时间:2021-04-20 15:29:36    阅读次数:0
2017省赛A第4题
参考文章 1 #include<bits/stdc++.h> 2 using namespace std; 3 4 int X[] = {0, -1, 1, 0, 0}; 5 int Y[] = {0, 0, 0, -1, 1}; 6 7 bool vis[10][10]; 8 int res = ...
分类:其他好文   时间:2021-04-20 14:10:10    阅读次数:0
Solution -「YunoOI 2017」由乃的 OJ
Description Link. 起床困难综合症 上树。 Solution 线段树维护,树剖上树。 具体题解有空再写,我要去睡觉了。 #include<bits/stdc++.h> typedef unsigned long long ULL; struct node { ULL one,zero ...
分类:其他好文   时间:2021-04-19 15:09:51    阅读次数:0
CSAPP
只能用指定字符,实现函数功能 /* * CS:APP Data Lab * * <Please put your name and userid here> * * bits.c - Source file with your solutions to the Lab. * This is the ...
分类:移动开发   时间:2021-04-15 12:42:58    阅读次数:0
sw抄来的主席树
//本模板是离散后对权值建树 #include<bits/stdc++.h> #define mid (l+r>>1) using namespace std; const int N=2e5+10; struct TR { int sum,lo,ro; }tr[N<<5]; int tr_cnt; ...
分类:其他好文   时间:2021-04-15 12:28:09    阅读次数:0
8842条   上一页 1 ... 7 8 9 10 11 ... 885 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!