E-COM-NET
首页
在线工具
Layui镜像站
SUI文档
联系我们
推荐频道
Java
PHP
C++
C
C#
Python
Ruby
go语言
Scala
Servlet
Vue
MySQL
NoSQL
Redis
CSS
Oracle
SQL Server
DB2
HBase
Http
HTML5
Spring
Ajax
Jquery
JavaScript
Json
XML
NodeJs
mybatis
Hibernate
算法
设计模式
shell
数据结构
大数据
JS
消息中间件
正则表达式
Tomcat
SQL
Nginx
Shiro
Maven
Linux
spaces
Xcode10适配
1.Xcode10报错中不能包含info.plist问题解决方法:选择File--->work
spaces
ettings--->buildsystem改成legacyBuildSystem即可。
iOS_Ru
·
2023-12-16 07:31
DFS模板及入门题目
DFS模板voiddfs(intstep){//判断边界//遍历每一种可能for(i=1;iusingname
spaces
td;//n代表箱子(扑克)总数,flag代表该扑克是否被使用,li是排列出的队列
champion孺
·
2023-12-16 07:51
算法
算法
算法基础之迪杰斯特拉求最短路I
迪杰斯特拉求最短路I核心思想:迪杰斯特拉算法稠密图:用邻接矩阵存稀疏图:用邻接表存#include#include#includeusingname
spaces
td;constintN=510;intn
阳光男孩01
·
2023-12-16 06:13
算法
图论
数据结构
深度优先
c++
算法基础之有向图的拓扑序列
有向图——入度(有几条边指向自己)出度(自己有几条边指向别人)边都是由小指向大1->32->31->2将所有入度为0的点入队列—>宽搜#include#include#includeusingname
spaces
td
阳光男孩01
·
2023-12-16 06:43
算法
数据结构
散列表
图论
c++
算法基础之字符串哈希
进制数储存字符串每一位数的hash值L—R的哈希值=h[R]-h[L-1]*PR-L+1哈希值很大—>modQ(264)变小==用unsignedlonglong存(出界)#includeusingname
spaces
td
阳光男孩01
·
2023-12-16 06:42
算法
哈希算法
数据结构
c++
散列表
图论
算法基础之图中点的层次
图中点的层次核心思想:BFS树与图的广度优先遍历#include#include#include#includeusingname
spaces
td;constintN=100010;intn,m;intd
阳光男孩01
·
2023-12-16 06:42
算法
图论
c++
数据结构
广度优先
B. Milena and Admirer(贪心)
Problem-B-Codeforces解析:每次贪心分解为不降并且左端尽量大即可#includeusingname
spaces
td;#defineintlonglongconstintN=2e5+5;
陈进士学习
·
2023-12-16 05:29
codeforces
c++
算法
开发语言
数据结构
c语言
贪心
CF1898B Milena and Admirer(贪心)
题目链接题目大意有一个长度为n的数组做操作使这个数组不递减:把一个数分成两个数,例如:x分为a和b,x==a+b求最小操作次数思路见注释代码#include#defineintlonglongusingname
spaces
td
x-d-xxh
·
2023-12-16 05:26
CF
贪心
思维题
算法
c++
数据结构
1115 Counting Nodes in a BST(30 分)
先建树,之后BFS或者DFS都可以BFS:#include#include#includeusingname
spaces
td;structnode{intdata,layer;node*lchild,*
DaiMorph
·
2023-12-16 05:41
Week 8 最短路径问题
模板】Floyd-洛谷|计算机科学教育新生态(luogu.com.cn)https://www.luogu.com.cn/problem/solution/B3647#includeusingname
spaces
td
棠梨下
·
2023-12-16 03:05
算法
ACM 预备队训练 第八周 最短路径
#includeusingname
spaces
td;intM=0x7FFFFFFF;intn,m,a[101][101],min1,next1=77;intvis[101],dis[101];inttermin
LYB0130
·
2023-12-16 03:35
图论
算法
2023NEUQACM Week8
完整代码如下:#includeusingname
spaces
td;#defineM105#defineinf0x7FFFFFFFintn,m,u,v,w,Min,nex;intMap[M][M];intDist
ClarusXie
·
2023-12-16 03:04
NEUQACM
图论
算法
俱乐部训练题8
这些题挺折磨我的B3647【模板】Floyd-洛谷|计算机科学教育新生态(luogu.com.cn)#includeusingname
spaces
td;intmain(){longlongmap[105
Alasco
·
2023-12-16 03:34
算法
digit函数
代码:#includeusingname
spaces
td;intmain(){stringn;intk;cin>
Dream_MC_LZR
·
2023-12-16 03:35
算法
人口增长问题
输入输出样例输入#11310输出#113.1306这道题没什么其他可以讲的,只需要用以下公式:x+=x/1000.0代码如下:#includeusingname
spaces
t
Dream_MC_LZR
·
2023-12-16 03:35
算法
数据结构
分苹果给大家
输入输出样例输入#18输出#136所以,这道题我们只需要计算出1~n的累加就行了话不多说,直接上代码:#includeusingname
spaces
td;intmain(){intn
Dream_MC_LZR
·
2023-12-16 03:05
算法
LLM(七)| Mamba:LLM新架构的浅探
我们将从以下几个方面重点介绍基于新架构的语言模型:Mamba模型(https://github.com/state-
spaces
/mamba):与基础模型对话使用HuggingfaceTrainer进行指令跟随微调从速度和输出质量方面在
wshzd
·
2023-12-16 02:53
ChatGPT
NLP
笔记
chatgpt
笔记
人工智能
JVM虚拟机:GC垃圾回收器的常用参数总结
GC常用的参数列表-Xms:堆空间最小为多少-Xmx:堆空间最大为多少-Xss:栈空间大小-Xmn:年轻代的空间大小-XX:Meta
spaceS
ize:元空间大小-XX:+PrintGCDetails:
幻风_huanfeng
·
2023-12-16 02:52
深入了解JVM虚拟机
jvm
java
算法
垃圾回收器
垃圾回收算法
数据结构六:二叉树非递归遍历
dataleftrightflagflag用于后顺遍历时标记右侧树的访问状态,若左右子树都被访问后(为null或者flag==1),则可以弹出当前节点并打印.三源码#include#includeusingname
spaces
td
奋进的码牛
·
2023-12-16 01:45
数据结构
算法
【C++入门】C++初识
1.1.3编写代码#includeusingname
spaces
td;intmain(){coutusingnamesp
小卓仗剑走天涯
·
2023-12-16 01:41
C++
从入门到精通
c++
visual
studio
开发语言
6.4-6.5 C++11线程局部存储与快速退出:quick_exit与at_quick_exit
#include#include#includeusingname
spaces
td;interrorCode=0;
小黑屋1024
·
2023-12-16 01:26
深入理解C++11新特性
C++11
n个结点,第i个结点的权值为a[i],给定c,如果a[i] + a[j] >= i * j * c, 那么i和j直接可以连一条边,并且i、j缩成一个点,权值为两点权值之和, 编号为min(i, j)
和其他结点连边一定是最优解之一,假设有三个结点,2,3可以连边,那么有a[2]+a[3]>=2*3*c(那么a[2],a[3]至少有一个大于等于3c),1不能和2、3连,有a[1]+a[2]usingname
spaces
td
__night_
·
2023-12-16 01:12
codeforces
c语言
算法
开发语言
给定一个01串s,每次能在任意位置插入01,求能否在300次操作内,使得s满足对任意1 <= i <= n, s[i] != s[n - i + 1],若能输出操作次数和插入位置
题目#includeusingname
spaces
td;constintmaxn=105;strings;voidsolve(){intn;//s=string(1000);cin>>n>
__night_
·
2023-12-16 01:12
codeforces
算法
给定长度为n的序列a和p,求对于p[i](1 <= i <= n), gcd{a[1] + p[i], a[2] + p[i], ... , a[n] + p[i]}的最小值和最大值
题目思路:#includeusingname
spaces
td;#defineintlonglongconstintmaxn=2005;inta[maxn],b[maxn],c[maxn];signedmain
__night_
·
2023-12-16 01:11
牛客
算法
c++
给定序列a,选k个数排成一排,从左往右扫,如果当前数小于上一个数,那么当前数变成上一个数,然后形成最后的序列,问形成的序列有多少种
题目#includeusingname
spaces
td;#defineintlonglongconstintmaxn=3005,mod=1e9+7;inta[maxn],b[maxn],cnt_low[
__night_
·
2023-12-16 01:41
2023杭电多校
算法
有n件物品,每件物品都有一个花费,要求每m个中必须至少选2个,求最小花费
题目#includeusingname
spaces
td;#defineintlonglong#pragmaGCCoptimize(2)constintmaxn=2e4+5,maxm=2e3+5,inf=
__night_
·
2023-12-16 01:41
2023杭电多校
算法
程序员面试金典: 9.4树与图 4.3给定一个有序整数数组,元素各不相同且按升序排列,创建一颗高度最小的二叉查找树。
#include#include#include#include#include#include#includeusingname
spaces
td;/*问题:给定一个有序整数数组,元素各不相同且按升序排列
天地一扁舟
·
2023-12-16 00:08
程序员面试金典
给定有n个结点的树和长度为n的排列,q次询问:l, r, x, 若p[l, r]中存在至少一个结点是x的后代,输出yes,否则输出no
题目#includeusingname
spaces
td;constintmaxn=1e6+5;intn,q;vectorG[maxn];intL[maxn],R[maxn];//L[i]表示结点i的时间戳
__night_
·
2023-12-16 00:27
codeforces
开发语言
《C++新经典设计模式》之第11章 组合模式
《C++新经典设计模式》之第11章组合模式组合模式.cpp组合模式.cpp#include#include#include#include#include#includeusingname
spaces
td
mali378287007
·
2023-12-16 00:57
C/C++
设计模式
c++
设计模式
组合模式
2022 China Collegiate Programming Contest (CCPC) Mianyang Onsite
stheTrick记dpdpdp状态为dp[i][j][k]dp[i][j][k]dp[i][j][k],为在第iii轮,A变了jjj次,B变了kkk次,然后直接开始搜索#includeusingname
spaces
td
伏地嘤嘤怪
·
2023-12-16 00:52
深度优先
算法
图论
C语言编程100例子
#include"stdafx.h"#include#include#includeusingname
spaces
td;structStudent{intnumber;//xuehaocharname[
乌拉_乌拉_乌拉
·
2023-12-16 00:51
c语言
c++
visual
studio
蓝桥杯C/C++B组省赛日期类问题汇总
第八届省赛第七题日期问题思路:暴力枚举从1960年1月1日到2059年12月31日的所有合法日期,然后拆分出年月日,如果符合题目中的三种情况之一(年/月/日月/日/年日/月/年)的输出即可#includeusingname
spaces
td
Wpiper
·
2023-12-16 00:17
蓝桥杯
蓝桥杯
C语言网题目 1882: 蓝桥杯2017年第八届真题-k倍区间
倍区间题目链接:C语言网题目1882:蓝桥杯2017年第八届真题-k倍区间题目描述给定一个长度为N的数列,A1,A2,...AN,如果其中一段连续的子序列Ai,Ai+1,...Aj(iusingname
spaces
td
程序员shy
·
2023-12-15 23:09
《算法刷题》
蓝桥杯
序列上等式计数
题目 1873: 蓝桥杯2017年第八届真题-合根植物
输入第一行,两个整数m,n,用空格分开,表示格子的行数、列数(1usingname
spaces
td;vectordp[1000000];intlen[1000000];//记录dp每一个数字可以通向的树木
莓莓不加糖
·
2023-12-15 23:08
蓝桥杯真题(C/C++)
蓝桥杯
c语言
深度优先
C++学习——二叉树的操作
前言二叉树的原理代码实现/*二叉树的学习参考:https://blog.csdn.net/guokeyan22/article/details/50758922*/#include#includeusingname
spaces
td
侠之大者_7d3f
·
2023-12-15 23:39
2023/12/4作业
1.2.程序:#includeusingname
spaces
td;classSofe{private:stringsiting;double*sofe;public:Sofe(){cout<<"Sofe
sadjjkj
·
2023-12-15 23:54
c++
国内首本!《牛客2023金融科技·校园招聘白皮书》发布(附下载)
秋招0of双飞鼠鼠的梦佬们想请问下如果签保底,还想找更好的需要考虑哪些问题呀(三方方面),签了保底还有机会去其他公司吗题解|#判断身材状态##includeusingname
spaces
td;intmain
愤怒的小青春
·
2023-12-15 23:09
java
C++_对C数据类型的扩展
结构体c++中定义结构体变量,可以省略struct关键字c++结构提重可以直接定义函数,谓之成员函数(方法)#includeusingname
spaces
td;structstu{intnum;charname
小辰017
·
2023-12-15 22:55
c++
c语言
算法
C++——引用
语法格式如下:类型&引用名=变量名;#includeusingname
spaces
td;intmain(intargc,constchar*argv[]){inti=100;int&ir=i;//给变量
小辰017
·
2023-12-15 22:55
c++
java
算法
C++核心编程
后缀C++兼容C,C++也可以使用stdio.h也提供C++风格的头文件,如cstdio,该头文件一般存在于/usr/include/c++/4.8/*/#inclucd//名字空间usingname
spaces
td
小辰017
·
2023-12-15 22:25
c++
开发语言
题目:分糖果(蓝桥OJ 2928)
题目描述:解题思路:本题采用贪心思想图解题解:#includeusingname
spaces
td;constintN=1e6+9;chars[N];//写字符串数组的一种方法,像数组一样***intmain
猫猫猫喵
·
2023-12-15 21:35
算法
数据结构
题目:二进制中1的个数 (蓝桥OJ 1331)
题目描述:解题思路:使用位运算.右移并判断最低位是否为一.但需要注意一般的int类型不行,要使用unsignedint.题解:#includeusingname
spaces
td;intmain(){unsignedintx
猫猫猫喵
·
2023-12-15 21:35
算法
题目:区间或 (蓝桥OJ 3691)
解题思路:本题采用位运算.先求出全部数组每一位各自的前缀和,然后再判断区间内每一位区间和是否为0,不为0则乘上相应的2^n并将各个为的2^n相加,得ans.实现原理图题解:#includeusingname
spaces
td
猫猫猫喵
·
2023-12-15 21:35
算法
数据结构
题目:谈判(蓝桥OJ 545)
题解:#includeusingname
spaces
td;usingll=longlong;//元素值可能超过ll。后面的x,y,ans都需要llpriority_qu
猫猫猫喵
·
2023-12-15 21:05
算法
题目:小明和完美序列(蓝桥OJ 3199)
题解:#includeusingname
spaces
td;map>p;setq;//去重记录数字intmain(){intn;cin>>n;for(inti=0;i>x;p[x].push_back(x
猫猫猫喵
·
2023-12-15 21:35
算法
c++
数据结构
题目:小蓝的括号串1(蓝桥OJ 2490)
题解:#includeusingname
spaces
td;constintN=1e6+9;//大小大于1e2即可chars[N];//也可以写成string,但要注意最后的s[i]类型为charintmain
猫猫猫喵
·
2023-12-15 21:34
算法
题目:快速幂(蓝桥OJ 1514)
题解:#includeusingname
spaces
td;usingll=longlong;llksm(lla,llb,llc)//注意:需要取模的地方都取模c,且多处地方取同一模不影响结果{llres
猫猫猫喵
·
2023-12-15 21:30
算法
《C++新经典设计模式》之第9章 命令模式
《C++新经典设计模式》之第9章命令模式命令模式.cpp命令模式.cpp#include#include#includeusingname
spaces
td;//5种角色//Receiver(接收者),Cook
mali378287007
·
2023-12-15 21:24
C/C++
设计模式
c++
设计模式
命令模式
内存对齐规则
对齐规则:从内存偏移0开始存储变量的起始位置是变量大小的整数倍结构体总大小是最大元素的整数倍如果有pragmapack(n),取n和变量大小中小的那个#includeusingname
spaces
td;
曹小恒
·
2023-12-15 21:25
C# UDP接收数据 多线程
UDP接收数据usingSystem;usingSystem.Net;usingSystem.Net.Sockets;usingSystem.Text;name
spaceS
witcher{classUDPReceive
小~小
·
2023-12-15 20:43
Visual
Studio
c#
udp
开发语言
上一页
106
107
108
109
110
111
112
113
下一页
按字母分类:
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
其他