码迷,mamicode.com
首页 >  
搜索关键字:es6 let const    ( 43838个结果
dik
#include<bits/stdc++.h> using namespace std; const int N = 200000,Inf=0x7fffff; struct edge{ int u,v,w; edge(int a,int b,int c){ u=a,v=b,w=c; } }; vec ...
分类:其他好文   时间:2021-06-02 17:40:23    阅读次数:0
js 检测链表是否有环
set 判重 利用节点的内存地址来进行判重 var hasCycle = function (head) { let set = new Set(); let p = head; while (p) { //存在重复 if (set.has(p)) { return true; } set.add( ...
分类:Web程序   时间:2021-06-02 17:29:00    阅读次数:0
nodeJs爬取网络图片
const cheerio = require("cheerio") const axios = require("axios") const fs = require("fs") if (!fs.existsSync("download")) { fs.mkdirSync("download", ...
分类:Web程序   时间:2021-06-02 17:04:51    阅读次数:0
换根dp
#include <iostream> #include <vector> using namespace std; using ll = long long ; const int N=2e5+10; ll f[N],g[N],size1[N]; vector<int>gg[N]; void df ...
分类:其他好文   时间:2021-06-02 17:01:29    阅读次数:0
node 连接MySql数据库 实现数据的CRUD
1,准备工作: 安装MySQL2 驱动(库名称为mysql2 ): npm install mysql2 2,编写js代码: 2-1,数据库 查询 数据js代码 const mysql = require('mysql2') const connection = mysql.createConnec ...
分类:数据库   时间:2021-06-02 17:00:22    阅读次数:0
dd爱框框
dd爱框框 一道思维题,画过转换图之后会发现最多会出现四种矩阵,那么只需要判断最后是哪一种就好了。 同时对于连续的直接去重,因为两个连续相同的等于不操作。 #include <bits/stdc++.h> using namespace std; const int N = 1010; int a[ ...
分类:其他好文   时间:2021-06-02 16:40:21    阅读次数:0
ICPC2021南京区域赛 L.Let's Play Curling(二分、思维、构造)
题目:Let's Play Curling 题意:给出n个红点,m个蓝点在数轴上,问是否能找到一个实数点c,满足一些红色的点到点c的距离绝对值小于任意的蓝点到点c的绝对值,最多能有几个红色的点能满足该条件,若无则输出Impossible,否则输出能满足该条件红点的个数. 解析:实际上就是找出任意两个 ...
分类:Web程序   时间:2021-06-02 16:10:52    阅读次数:0
CF 580E Kefa and Watch
#include<bits/stdc++.h> #define ull unsigned long long using namespace std; const int N=1000011; const ull St=233,M1=1000000007,M2=1000000009; int n,m ...
分类:其他好文   时间:2021-06-02 16:00:05    阅读次数:0
[ AGC006 D ] Median Pyramid Hard
题目 Atcoder 思路 代码 #include <iostream> using namespace std; const int N = 200010; int n, m, a[N], b[N]; int check(int mid) { for (int i = 1; i <= n * 2 ...
分类:其他好文   时间:2021-06-02 15:33:04    阅读次数:0
[ AGC006 E ] Rotate 3x3
题目 Atcoder 思路 代码 #include <iostream> #include <cstring> #include <algorithm> using namespace std; const int N = 100010; int n, w[4][N], to[N], st[N]; ...
分类:其他好文   时间:2021-06-02 15:31:22    阅读次数:0
43838条   上一页 1 ... 21 22 23 24 25 ... 4384 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!