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
whil
4、LED闪烁
j,k;//_nop_()需要导入包_nop_();i=4;j=205;k=187;do{do{while(--k);}while(--j);}while(--i);}voidmain(){//死循环
whil
rjr.ToString
·
2023-11-26 20:39
物联网-51单片机
单片机
嵌入式硬件
51单片机
物联网
iot
CodeTON Round 5 (Div. 1 + Div. 2, Rated, Prizes!) F. Tenzing and Tree(绝对值等式+树的重心性质+贡献)
0x3f3f3f3f;vectore[N];intn,u,v,mn[N],dis[N];voidbfs(intu){for(inti=1;iq;q.push(u);dis[u]=0;intc=0,sum=0;
whil
Code92007
·
2023-11-26 16:40
树
绝对值等式
树的重心
枚举贡献
c语言习题---(循环语句)
题目目录非编程题第一题:#includeintmain(){intn=0;
whil
叶超凡
·
2023-11-25 17:39
c语言习题
c语言
ROS下键盘控制小车运动
设定好一个固定的速度值:doublelinear_speed=1.0;//线速度设为1m/sdoubleangular_speed=1.0;//角速度设为1rad/s然后就可以获取键盘的信息,来控制无人车进行运动:
whil
木子Robot
·
2023-11-24 07:13
机器人
C语言第十八弹---多个字符从两端移动向中间汇聚
includeintmain(){chararr1[]="helloworld";chararr2[]="***********";intsz=strlen(arr1);intleft=0;intright=sz-1;
whil
沉迷于敲代码的小秦
·
2023-11-22 09:58
c语言
开发语言
计算器(一个四年级小朋友编出来的)
="F")ew=1;system("cls");cout>o;}
whil
滑 铁 卢
·
2023-11-19 23:13
c++
【LeetCode刷题-二分查找】--278.第一个错误的版本
intversion);*/publicclassSolutionextendsVersionControl{publicintfirstBadVersion(intn){intleft=1,right=n;
whil
小d<>
·
2023-11-12 11:42
#
二分查找
leetcode
算法
搜索与图论:有向图的拓扑序列—拓扑排序
includeusingnamespacestd;constintN=100010;intru[N];queueq;vectorres;map>list;intn,m;booltopsort(){for(inti=1;i>n>>m;
whil
奋斗吧!骚年!
·
2023-11-12 01:28
#
搜索与图论
图论
c++
算法
宽度优先遍历
拓扑排序
[题解]洛谷P1908 逆序对
longlongR,longlongT[]){if(R-L>1){longlongM=L+(R-L)/2;longlongp=L,q=M,i=L;sort(A,L,M,T);sort(A,M,R,T);
whil
weixin_30471561
·
2023-11-11 01:32
数据结构与算法
Day 03 | 链表专题与虚拟头节点
=nullptr&&head->val==val){head=head->next;}注意:是
whil
To achieve my dream
·
2023-11-10 06:00
算法
leetcode
链表
剑指Offer11-旋转数组中的最小数-二分
操作的是l+1而且最后返回的也是num[l]代码如下:classSolution{public:intminArray(vector&numbers){intl=0,r=numbers.size()-1;
whil
李烦烦搞快点
·
2023-11-07 18:04
剑指Offer
算法
c++
数据结构
二分
列表的基础知识
在使用
whil
编程可太难了
·
2023-11-02 09:35
python
LeetCode | 876. 链表的中间结点
这个时候第二个变量就是中间的那个值~~如图:代码如下:structListNode*middleNode(structListNode*head){structListNode*slow=head,*fast=head;
whil
仍然探索未知中
·
2023-11-01 23:25
LeetCode
leetcode
链表
算法
阶乘分之一求和公式C语言,n的阶乘分之一之和
Exceptionex){throw(ex);}floatsum=1;decimaltotal=0;for(inti=1;i0){a+=f.F(b);b--;}Console.WriteLine(a);}}
whil
小雨好矮哦
·
2023-10-31 14:21
阶乘分之一求和公式C语言
LeetCode 1346. 检查整数及其两倍数是否存在
所以二分查找要查找到下标,然后进行二次判断classSolution{publicintbinarySearch(int[]arr,inttarget){intleft=0,right=arr.length-1,mid;
whil
Sasakihaise_
·
2023-10-31 11:43
LeetCode
leetcode
二分查找
哈希表
#千峰#days15Set集合
school=newArrayListclas1=newArrayListclas2=newArrayListclas3=newArrayLists=newHashSetit=s.iterator();
whil
三行一路
·
2023-10-30 04:20
c语言中的while语句
*/intmain(){//形式1while循环//使用while循环求1到100的累加和inti=1;intsum=0;
whil
爱喝水的泡泡
·
2023-10-29 10:26
c语言
算法
开发语言
线程学习杂记1
若被唤醒,则会永远是
WHIL
qq_39483408
·
2023-10-28 13:37
解题思路-leetcode面试题 16.06. 最小差
},{23,127,235,19,8}输出:3,即数值对(11,8)提示:1int:a.sort()b.sort()n,m=len(a),len(b)i,j=0,0res=abs(a[i]-b[j])
whil
PPlemon1997
·
2023-10-28 05:30
指针
leetcode
算法
数据结构
Day06List接口&Set接口&树
(String[]args){//1.准备一个集合Collectioncollection=newArrayListiterator=collection.iterator();//3.使用迭代器遍历
whil
IT_Rocter
·
2023-10-25 02:40
java
开发语言
set维护连续段+线段树:1018T2
连续段之间分别统计,取max#includeusingnamespacestd;#defineintlonglonginlineintread(){intx=0,f=1;charch=getchar();
whil
Qres821
·
2023-10-19 20:49
线段树
数据结构
set
冒泡排序给cpu干懵了 哈哈 还有希尔排序 算法补充(学习笔记)
include"BubbleSort.h"usingnamespacestd;templatevoidshellSort(Tarr[],intn){//计算incrementsequence:1,4,13,40,121,364,1093...inth=1;
whil
:)�东东要拼命
·
2023-10-19 17:57
算法
算法
利用归并排序求逆序对数量
lll,llr){if(l>=r)return0;llmid=l+r>>1;llres=merge_sort(l,mid)+merge_sort(mid+1,r);intk=0,i=l,j=mid+1;
whil
路栖法504
·
2023-10-18 00:16
c++
算法
C语言——循环结构
一、
whil
比特阿豪·
·
2023-09-28 09:59
c语言
开发语言
基础练习 01字串
样例输出00000000010001000011solution1#includeintmain(){inta[5]={0};
whil
Moliay
·
2023-09-27 13:12
蓝桥杯
算法
数据结构
Leetcode 15
nums.end());for(inti=0;i0)returnres;if(i>0&&nums[i]==nums[i-1])continue;intleft=i+1;intright=nums.size()-1;
whil
Zoeyii935
·
2023-09-27 10:20
leetcode
算法
职场和发展
组合数3 - lucas a、b较大的组合数
n'usingnamespacestd;typedefpairPII;typedeflonglongll;typedeflongdoubleld;lla,b,mod;llqmi(lla,llk){llres=1;
whil
泠楠子
·
2023-09-26 23:23
模板
c++
算法
组合数
Python 打印文本进度条
for3、条件语句if4、重点:转义字符'\r',可以把光标移动到首行"""count=1#循环计次star=0#星号dit=20#点号#打印开始下载print('='*10+'开始下载'+'='*10)
whil
周华2022
·
2023-09-25 08:52
python
一起变强
python
python while循环语句break_Python break while-Python break while循环-Python break while语句-Python break
whil
.
Pythonbreakwhile循环教程在我们使用在while中,使用break结束循环的用法跟在Pythonbreakwhile循环详解语法whilecondition:#dosomethingifcondition1:break说明上面的循环是在condition条件满足的情况下,终止while循环。案例break语句终止while循环使用break语句,终止while循环print("嗨客网
weixin_39687189
·
2023-09-24 15:03
python
while循环语句break
leetcode:70. 爬楼梯(python3解法)
1.1阶+1阶+1阶2.1阶+2阶3.2阶+1阶提示:1int:fb_list=[1,2]ifn<=2:returnfb_list[n-1]
whil
心软且酷丶
·
2023-09-20 02:31
python
算法
leetcode
算法
python
CCF CSP题解:最大的矩形(201312-2)
scanf("%d",&n);//矩形个数int*rec=(int*)malloc(n*sizeof(int));//矩形图for(inti=0;i=0&&rec[left-1]>=h){left--;}
whil
曹无悔
·
2023-09-17 09:26
CCF
CSP
算法与数据结构
算法
数据结构
CCF
CSP
c语言
c++
Python while循环嵌套
:print(f"打印第{i}行")#定义列j=1#打印8列whilej<=8:print(f"打印第{j}列",end="")j+=1print()i+=1print("哇哇,打印完了")作业:通过
whil
java1234_小锋
·
2023-09-15 11:46
Python
python
算法——快乐数
intn){intsum=0;while(n){intt=n%10;sum+=t*t;n/=10;}returnsum;}boolisHappy(intn){intslow=n,fast=Sum(n);
whil
Nick-An
·
2023-09-15 10:14
算法
hdu1257(最长上升子序列)
ac代码:#includeusingnamespacestd;inta[1000000],dp[1000000];intmain(void){intN;
whil
42fighting
·
2023-09-12 18:51
力扣题解(54. 螺旋矩阵),带注释
length;//int[]ans=newint[m*n];ArrayListlist=newArrayList();//定义4个边界intup=0,right=n-1,down=m-1,left=0;//
whil
teasing&poking
·
2023-09-11 13:05
力扣每日一题
读研的尽头是Java!
leetcode
矩阵
算法
io第二天
fopen("4.txt","w");if(NULL==fp){ERR_MSG("fopen");return-1;}printf("fopensuccess");size_tres=0;chart;
whil
孟孟能学会
·
2023-09-07 22:32
java
前端
javascript
【003】计算0至一个数字n之间指定数字k(1~9)的出现次数(含重复)
)获取最终答案算法公式:publicstaticintdigitCounts(intk,intn){inti=1;intcount=0;intcurrent=0;inthigh=0;intlow=0;
whil
一念久思
·
2023-09-02 08:07
intToRoman
以此类推;*/classSolution{publicStringintToRoman(intnum){intx=num;StringBuilderresult=newStringBuilder();
whil
走地牙
·
2023-09-01 01:41
/proc/net/dev 最后一行读2次
,r5,r6,r7,r8,t1,t2,t3,t4,t5,t6,t7,t8;inti=0;sample->rb=0;sample->tb=0;fp=fopen("/proc/net/dev","r");
whil
海天鹰
·
2023-08-28 21:01
C++
c++
基础算法--二分
//check()判断mid是否满足性质elsel=mid+1;}returnl;}//区间[l,r]被划分成[l,mid-1]和[mid,r]时使用:intbsearch_2(intl,intr){
whil
小符不秃头
·
2023-08-24 05:38
算法
java
数据结构
c++
【leetcode】第五章 栈与队列part02
privateStackout;publicMyQueue(){in=newStack();}publicvoidpush(intx){in.push(x);}publicintpop(){if(out.isEmpty()){
whil
编程小白呀
·
2023-08-20 05:47
刷题
leetcode
算法
【leetcode】第五章 栈与队列part01
privateStackout;publicMyQueue(){in=newStack();}publicvoidpush(intx){in.push(x);}publicintpop(){if(out.isEmpty()){
whil
编程小白呀
·
2023-08-20 05:45
刷题
leetcode
算法
无涯教程-Perl - setnetent函数
/usr/bin/perluseSocket;
whil
Hi无涯教程
·
2023-08-15 19:29
无涯教程
perl
2018-07-23
Treesgrowbothupwardsanddownwards.
Whil
福气东来
·
2023-08-14 17:03
和为target的连续正数序列(LeetCode面试题)
2,3,4],[4,5]]示例2:输入:target=15输出:[[1,2,3,4,5],[4,5,6],[7,8]]限制:1res=newList();inti=1;intj=1;intsum=0;
whil
倚剑赏雪
·
2023-08-10 11:04
LeetCode 热题 100JavaScript--2. 两数相加
varaddTwoNumbers=function(l1,l2){varcarry=0;//进位varresult=newListNode();//虚拟头节点varp=result;
whil
Bonjour_Yvonne
·
2023-08-09 23:53
力扣热题100
leetcode
算法
职场和发展
4.while循环
while循环//1、while循环语法结构
whil
这一片月
·
2023-08-09 10:37
javascript
无涯教程-Perl - do...while 语句函数
do...
whil
Hi无涯教程
·
2023-08-06 13:28
无涯教程
perl
Java控制语句
语句的语法结构:2.3switch语句的执行原理:3.for语句3.1语法结构:3.2for循环的执行原理:3.3九九乘法表4.while语句4.1while循环的语法结构4.2while循环的执行原理4.3
whil
茹嗨瑞
·
2023-08-03 13:43
Java学习笔记
java
开发语言
C1. Dual (Easy Version)(正负号转换)
代码献上(正负号转换):#includeusingnamespacestd;intq[30];intmain(){intT;cin>>T;q[0]=0;
whil
CCPC不拿奖不改名
·
2023-08-01 16:31
心得
经验
题解
算法
数据结构
推荐算法
c++
开发语言
上一页
1
2
3
4
5
6
7
8
下一页
按字母分类:
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
其他