板子 大王sample cpp

神必 cpp 语法合集

反向遍历 std::map 的时候删除迭代器 2023.4.19 decltype(mp)::iterator p = ++mp.erase(++it.base()); it = std::make_reverse_iterator(p); demo #include <bits/stdc++.h> ......
语法 cpp

cpp常用积累——eigen、csv读取

1.matrixXd 与 vector<double> 的互转 vector<double> 转 matrixXd Eigen::MatrixXd Vec_xx = Eigen::Map<Eigen::MatrixXd>(new_x.data(), new_x.size(),1); vector<d ......
常用 eigen cpp csv

cpp:Double Dimensional Array using vector 2

// StudentArry.h : 此文件包含 "StudentArry" 类。学生数组成绩显示方法 C++ 14 // 2023年4月9日 涂聚文 Geovin Du edit. //(1)vec1.size() 就是”二维数组”的行数 //(2)vec1[0].size() 就是”二维数组”的 ......
Dimensional Double vector Array using

论文解读(PAWS)《Semi-Supervised Learning of Visual Features by Non-Parametrically Predicting View Assignments with Support Samples》

论文信息 论文标题:Semi-Supervised Learning of Visual Features by Non-Parametrically Predicting View Assignments with Support Samples论文作者:Mahmoud Assran, Mathi ......

cpp:Double Dimensional Array using vector

// StudentArry.cpp : //练习案例:学生数组成绩显示方法 StudentArry //案例描述:学生数组成绩显示方法 #include "StudentArry.h" #include <iostream> #include <string> #include <vector> ......
Dimensional Double vector Array using

FastGCN Fast Learning with Graph Convolutional Networks via Importance Sampling

Chen J., Ma T. and Xiao C. FastGCN: fast learning with graph convolutional networks via importance sampling. ICLR, 2018. 概 一般的 GCN 每层通常需要经过所有的结点的 prop ......

几个板子

FHQ Treap 普通平衡树 struct treap { int l, r, siz, dat, val; } tr[N]; int idx, rt; int get_new(int val) { tr[++ idx].val = val; tr[idx].dat = rand(); tr[id ......
板子

cpp: SQLite

lib /def:sqlite3.def /machine:ix86 ......
SQLite cpp

cpp: vector

// NarcissisticInfo.h : //练习案例:水仙花数 100 - 1000 NarcissisticNumber //案例描述:水仙花数是指一个 3 位数,它的每个位上的数字的 3次幂之和等于它本身 //例如:1 ^ 3 + 5 ^ 3 + 3 ^ 3 = 153 //请利用do. ......
vector cpp

线段树区间和,区间修改,区间查询板子

#include <bits/stdc++.h> using namespace std; using LL = long long; #define lson (nd<<1) #define rson (nd<<1|1) #define mid (l+r>>1) const int N = 1e5 ......
区间 线段 板子

cpp: read csv file

// CSVfilemanagement.h : //练习案例:CSV 文件读写 // // 2023年4月5日 涂聚文 Geovin Du edit. // https://www.digitalocean.com/community/tutorials/getline-in-c-plus-plu ......
read file cpp csv

cpp: Narcissistic in C++11

// NarcissisticList.h : //练习案例:水仙花数 100 - 1000 NarcissisticList //案例描述:水仙花数是指一个 3 位数,它的每个位上的数字的 3次幂之和等于它本身 //例如:1 ^ 3 + 5 ^ 3 + 3 ^ 3 = 153 //请利用do... ......
Narcissistic cpp 11 in

cpp: 九九乘法表显示

// CardinalDirection.h : //练习案例:九九乘法表位置 CardinalDirection //案例描述:九九乘法表位置 // //2023年4月5日 涂聚文 Geovin Du edit. // #pragma once #ifndef CARDINALDIRECTION_ ......
乘法表 乘法 cpp

CPP基础语法

C++基础语法 基本数据类型的大小 不同编译器的内置类型大小不同,比如指针类型,同是x86-64的CPU,g++的指针大小为8,visual的指针大小为4,minGW指针大小为8 C++标准只保证基本数据类型有一个最小大小: 图源 记录几个常用类型的大小,都基于x86-64处理器架构 | | g++ ......
语法 基础 CPP

CPP内存管理

从内核到C++应用 整个系统的不同层级有着不同的内存管理器。 linux内核: 伙伴系统(以页为单位进行管理)、slab分配器(定制化的内存管理器)。 malloc\free库函数:使用系统调用mmap、sbrk,以及bins管理多个空闲链表(内存池)。有合并空闲块的操作。有两种方式管理内存: 如果 ......
内存 CPP

Do you know the bitwise sum sample demonstrated in "Neural Networks and Deep Learning" by autor Michael Nielsen?

Do you know the bitwise sum sample demonstrated in "Neural Networks and Deep Learning" by autor Michael Nielsen? Yes, I am familiar with the bitwise s ......
quot demonstrated Networks Learning bitwise

cpp: random

// RandomlySampled.h : 此文件包含 "RandomlySampled" 类。十个常用排序算法 C++ 11 // 2023年4月9日 涂聚文 Geovin Du edit. #pragma once #ifndef RANDOMLYSAMPLED_H #define RANDO ......
random cpp

cpp degbug - win gnu

$ tree -a . ├── .cache │ └── clangd │ └── index │ └── hello.cpp.48B5401E85030568.idx ├── .ccls ├── .ccls-cache │ ├── @C@@Users@dev@Desktop@gnuwin@test ......
degbug cpp win gnu

[paper reading]|IC-FPS: Instance-Centroid Faster Point Sampling Module for 3D Point-base

摘要: 本文说首次实现了大规模点云场景中基于点的模型的实时检测(<30ms); 首先指出FPS采样策略进行下采样是耗时的,尤其当点云增加的时候,计算量和推理时间快速增加; 本文提出IC-FPS;包含两个模块:local feature diffusion based background point ......

cpp: CLion 2022.3.2 run 运行中文乱码解决方式

按住 Ctrl+Shift+Alt+/ (不够快捷的快捷键...)选中Registry... 然后取消run.processes.with.pty CLion 2022.3.2 ......
乱码 方式 CLion 2022 cpp

cpp shared_future

#include <chrono> #include <ctime> #include <future> #include <iomainp> #include <iostream> #include <sstream> #include <uuid/uuid.h> std::string get_ ......
shared_future shared future cpp

cpp: sort Algorithmic

// TenSortAlgorithms.h : 此文件包含 "TenSortAlgotrthms" 类。十个常用排序算法 C++ 14 // 2023年4月5日 涂聚文 Geovin Du edit. #ifndef TENSORTALGORITHMS_H #define TENSORTALGOR ......
Algorithmic sort cpp

cpp generate random array then sort by quick sort

#include <chrono> #include <ctime>#include <iomainp> #include <iostream> #include <random> #include <sstream> std::string get_time_now() { std::chrono ......
sort generate random array quick

一道一板一眼的数位dp和二分结合的板子题

题目 1811E - Living Sequence 题意 找出第n个,数位中不含‘4’的数字 思路 数位dp + 二分 唯一要注意的就是纯dfs搜索会卡常(hh,就是复杂度太高了),用上一点记忆化 代码 const int N = 14; int dp[N][N]; int a[N]; int l ......
一板一眼 板子 数位 一道

yaml-cpp YAML格式处理库的介绍和使用(面向业务编程-文件格式处理)

yaml-cpp YAML格式处理库的介绍和使用(面向业务编程-文件格式处理) YAML格式介绍 YAML的格式介绍,有关ini、json和xml或许很多人已经很了解了,但是关于YAML,还有许多人不了解。YAML被设计成更适合人类阅读(我想正因为如此,所以相对来说更灵活,就导致到使用的时候很多人会 ......
格式 yaml-cpp 业务 文件 yaml

cpp: Sorting a List of Objects with Custom Comparator or Lambda Function

PigInfo.h #ifndef PIGINFO_H #define PIGINFO_H #include <iostream> #include<string.h> #include<math.h> using namespace std; /* 实体类 https://learn.micros ......
Comparator Function Sorting Objects Custom

cpp: create class

PigInfo.h #ifndef PIGINFO_H #define PIGINFO_H #include <iostream> #include<string.h> #include<math.h> using namespace std; /* 实体类 https://learn.micros ......
create class cpp

关于c/cpp内存存储中常量与指针的类型

辨析 下面两种类型 char* a = "abc"; //① char b[] = "123"; //② 123\0 char arr[14] = "ABC"; //③ strcat(arr, a); 上面2与3相同,只是相等一个是预留长度,一个是实体长度,但是好像如果对于2只是声明,没有赋值,那么 ......
常量 指针 内存 类型 cpp

对拍板子

以防忘记 三个cpp文件 a.cpp表示待拍文件, b.cpp表示暴力版本,data.txt表示生成的数据。 #include <bits/stdc++.h> using namespace std; void generateData(){ ofstream fout("input.txt"); ......
板子
共357篇  :11/12页 首页上一页11下一页尾页