STL常用遍历,查找,算法
目录
1.遍历算法
1.1for_earch
1.2transform
2.常用查找算法
2.1find,返回值是迭代器
2.1.1查找内置数据类型
2.1.2查找自定义数据类型
2.2fin_if 按条件查找元素
2.2.1查找内置的数据类型
2.2.2查找内置数据类型
2.3查找相邻元素adjeacent_find
2.4查找指定元素是否存在binarary_search
2.5统计元素的个数count
2.5.1统计内置数据类型
2.5.2统计自定义数据类型
2.6按条件统计元素个数
2.6.1统计内置数据类型
2.6.2统计自定义的数据类型
3.常用排序算法
3.1sort
1.遍历算法
1.1for_earch
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
//常用遍历算法 for_each//利用普通函数实现
void print01(int val)
{cout << val << " ";
}//仿函数(函数对象)本身是个类。不是一个函数
class print02
{
public:void operator()(int val){cout << val << " ";}
};
void test01()
{vector<int>v;for (int i = 0; i < 10; i++){v.push_back(i);}for_each(v.begin(), v.end(), print01);//第三个位置,普通函数是把函数名放过来cout << endl;for_each(v.begin(), v.end(), print02());//第三个位置需要传入函数对象//类名加小括号,创建出匿名对象
}
int main()
{test01();system("pause");return 0;
}
1.2transform
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
//常用遍历算法 transform//仿函数(函数对象)本身是个类。不是一个函数
class Transform
{
public://搬运过程中把每个元素取出来在返回回去,由于操作的是int型,所以返回intint operator()(int val){return val+100;//+100在搬到容器中}
};
class Myprint
{
public:void operator()(int val){cout << val << " ";}
};
void test01()
{vector<int>v;for (int i = 0; i < 10; i++){v.push_back(i);}vector<int>vTarget;//目标容器vTarget.resize(v.size());//目标容器 需要提前开辟空间,不然报错transform(v.begin(), v.end(), vTarget.begin(), Transform());//最后一个位置函数对象for_each(vTarget.begin(), vTarget.end(), Myprint());//最后一个位置函数对象cout << endl;
}
int main()
{test01();system("pause");return 0;
}
2.常用查找算法
2.1find,返回值是迭代器
2.1.1查找内置数据类型
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
#include<string>
//常用查找算法
//find//查找 内置数据类型
void test01()
{vector<int>v;for (int i = 0; i < 10; i++){v.push_back(i);}//查找 容器中 是否有 5 这个元素vector<int>::iterator it = find(v.begin(), v.end(), 50);if (it == v.end()){cout << "没有找到!" << endl;}else{cout << "找到:" << *it << endl;}
}int main()
{test01();system("pause");return 0;
}
2.1.2查找自定义数据类型
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
#include<string>
//常用查找算法
//findclass Person
{
public:Person(string name, int age){m_Name = name;this->m_Age = age;}//重载== 让底层find知道如何对比person数据类型bool operator ==(const Person& p)//const防止修改p{if (this->m_Name == p.m_Name && this->m_Age == p.m_Age){return true;}else{return false;}}string m_Name;int m_Age;
};
//查找 自定义数据类型
void test02()
{vector<Person>v;//创建数据Person p1("aaa", 10);Person p2("bbb", 20);Person p3("ccc", 30);Person p4("ddd", 40);//放到容器中v.push_back(p1);v.push_back(p2);v.push_back(p3);v.push_back(p4);Person p("bbb", 20);//查找是否有和p一样的vector<Person>::iterator it = find(v.begin(), v.end(), p);if (it == v.end()){cout << "没有找到" << endl;}else{cout << "找到元素:姓名:" << (*it).m_Name << " 年龄:" << it->m_Age << endl;}}
int main()
{test02();system("pause");return 0;
}
2.2fin_if 按条件查找元素
2.2.1查找内置的数据类型
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
#include<string>
//常用查找算法
//find_if//1.查找内置数据类型
class GreaterFive
{
public://谓词返回boolbool operator()(int val)//find_if的底层也是取出每个元素并解引用,放到重载小括号里去操纵{return val > 5;//大于5 的时候就返回真}
};
void test01()
{vector<int>v;for (int i = 0; i < 10; i++){v.push_back(i);}//返回一个迭代器vector<int>::iterator it=find_if(v.begin(), v.end(), GreaterFive());//第三个位置是匿名函数对象if (it == v.end()){cout << "没有找到大于5的元素" << endl;}else{cout << "找到大于5的数字为:" << *it << endl;}
}//2.查找自定义数据类型int main()
{test01();system("pause");return 0;
}
2.2.2查找内置数据类型
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
#include<string>
//常用查找算法
//find_if//2.查找自定义数据类型
class Person
{
public:Person(string name, int age){m_Name = name;this->m_Age = age;}string m_Name;int m_Age;
};
class Great20
{
public:bool operator()(Person &p)//每个数据类型都是Perosn的数据类型用引用的方式传进来{return p.m_Age > 20;}
};
bool G2(Person& p)
{return p.m_Age > 20;
}
void test02()
{vector<Person>v;//创建数据Person p1("aaa", 10);Person p2("bbb", 20);Person p3("ccc", 30);Person p4("ddd", 40);v.push_back(p1);v.push_back(p2);v.push_back(p3);v.push_back(p4);//找年龄大于20的人vector<Person>::iterator it = find_if(v.begin(), v.end(), Great20());if (it == v.end()){cout << "没有找到" << endl;}else{cout << "找到姓名:" << (*it).m_Name << "年龄:" << it->m_Age << endl;}vector<Person>::iterator it1 = find_if(v.begin(), v.end(), Great20());if (it1 == v.end()){cout << "没有找到" << endl;}else{cout << "找到姓名:" << (*it1).m_Name << "年龄:" << it1->m_Age << endl;}
}
int main()
{test02();system("pause");return 0;
}
2.3查找相邻元素adjeacent_find
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
//常用查找算法
//adjacent_find
void test01()
{vector<int>v;v.push_back(0);v.push_back(2);v.push_back(0);v.push_back(3);v.push_back(1);v.push_back(4);v.push_back(3);v.push_back(3);vector<int>::iterator it=adjacent_find(v.begin(), v.end());if (it == v.end()){cout << "未找到相邻重复元素" << endl;}else{cout << "找到相邻重复元素:" << *it << endl;}
}int main()
{test01();system("pause");return 0;
}
2.4查找指定元素是否存在binarary_search
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
//常用查找算法
//binary_search 二分查找法,在无序的序列中不可以用
void test01()
{vector<int>v;for (int i = 0; i < 10; i++){v.push_back(i);}//查找容器中是否有9//注意容器必须是有序的序列//如果无序结果未知bool ret = binary_search(v.begin(), v.end(), 9);if (ret){cout << "找到了元素" << endl;}else{cout << "没找到" << endl;}
}int main()
{test01();system("pause");return 0;
}
2.5统计元素的个数count
2.5.1统计内置数据类型
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
//常用查找算法
//count//1.统计内置数据类型
void test01()
{vector<int>v;v.push_back(10);v.push_back(40);v.push_back(30);v.push_back(40);v.push_back(20);v.push_back(40);int num=count(v.begin(), v.end(), 40);cout << "40的元素个数为:" <<num<< endl;int num1 = count(v.begin(), v.end(), 1);cout << "1的元素个数为:" << num1 << endl;//输出0
}int main()
{test01();system("pause");return 0;
}
2.5.2统计自定义数据类型
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
//常用查找算法
//count//2.统计自定义数据类型
class Person
{
public:Person(string name, int age){m_Name = name;this->m_Age = age;}bool operator==(const Person& p)//底层要加const,{if (m_Age==p.m_Age){return true;}else{return false;}}string m_Name;int m_Age;
};
void test02()
{vector<Person>v;Person p1("刘备", 35);Person p2("关羽", 35);Person p3("张飞", 35);Person p4("赵云", 30);Person p5("曹操", 40);//将人员插入到容器中v.push_back(p1);v.push_back(p2);v.push_back(p3);v.push_back(p4);v.push_back(p5);Person p("诸葛亮", 35);//统计与诸葛亮年龄相同的有几人int num = count(v.begin(), v.end(), p);cout << "和诸葛亮同岁数的人员个数为:" << num << endl;
}int main()
{test02();system("pause");return 0;
}
2.6按条件统计元素个数
2.6.1统计内置数据类型
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
//常用查找算法
//count_if//1.统计内置数据类型
class Greater20
{
public:bool operator()(int val){return val > 20;}
};
void test01()
{vector<int>v;v.push_back(10);v.push_back(40);v.push_back(30);v.push_back(20);v.push_back(40);v.push_back(20);int num = count_if(v.begin(), v.end(), Greater20());cout << "大于20的元素个数为:" << num << endl;
}int main()
{test01();system("pause");return 0;
}
2.6.2统计自定义的数据类型
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
//常用查找算法
//count_if//2.统计自定义的数据类型
class Person
{
public:Person(string name, int age){m_Name = name;this->m_Age = age;}string m_Name;int m_Age;
};class AgeGreater20
{
public:bool operator()(Person &p){return p.m_Age > 20;}
};void test02()
{vector<Person>v;Person p1("刘备", 35);Person p2("关羽", 35);Person p3("张飞", 35);Person p4("赵云", 40);Person p5("曹操", 20);v.push_back(p1);v.push_back(p2);v.push_back(p3);v.push_back(p4);v.push_back(p5);//统计 大于20岁人员个数int num = count_if(v.begin(), v.end(), AgeGreater20());cout << "大于20的元素个数为:" << num << endl;
}int main()
{test02();system("pause");return 0;
}
3.常用排序算法
3.1sort
#include<iostream>
using namespace std;
#include<vector>
#include<algorithm>
//常用排序算法
//sort
void myPrint(int val)
{cout << val << " ";
}
void test01()
{vector<int>v;v.push_back(10);v.push_back(30);v.push_back(50);v.push_back(20);v.push_back(40);//利用sort进行升序,默认情况下升序sort(v.begin(), v.end());for_each(v.begin(), v.end(), myPrint);cout << endl;//改变为降序sort(v.begin(), v.end(), greater<int>());//greater<int>()内建函数对象,需要包含functional头文件,编译器高的不包含functional头文件也不会出错for (int i = 0; i < v.size(); i++){cout << v[i] << " ";}cout << endl;
}int main()
{test01();system("pause");return 0;
}
bool compare(int a,int b)
{ return a < b; //升序排列,如果改为return a>b,则为降序
}
int a[20]={2,4,1,23,5,76,0,43,24,65},i;
for(i=0;i<20;i++) cout<< a[i]<< endl;
sort(a,a+20,compare);
#include<iostream>
using namespace std;
#include<stack>
#include<algorithm>
#include<bitset>
#include<cmath>
#include<queue>
#include<set>
#include<map>struct Point
{int x;int y;//Point(int xx, int yy) :x(xx), y(yy) {};bool operator < (Point& p) {if (x != p.x) {return x < p.x;} else {return y < p.y;}}
};int main()
{vector<Point> p;p.push_back(Point{ 1,2 });p.push_back(Point{ 1,3 });Point p1;p1.x = 2;p1.y = 1;p.push_back(p1);sort(p.begin(), p.end());for (int i = 0; i < p.size(); i++) {cout << p[i].x << " " << p[i].y << endl;}/*输出:1 21 32 1*/system("pause");return 0;
}--------------------------------------------------------------------------------------struct Point
{int x;int y;
};
bool Cmp(Point& p1, Point& p2) {if (p1.x != p2.x) {return p1.x < p2.x;} else {return p1.y < p2.y;}
}int main()
{vector<Point> p;p.push_back(Point{ 1,2 });p.push_back(Point{ 1,3 });Point p1;p1.x = 2;p1.y = 1;p.push_back(p1);sort(p.begin(), p.end(),Cmp);for (int i = 0; i < p.size(); i++) {cout << p[i].x << " " << p[i].y << endl;}/*输出:1 21 32 1*/system("pause");return 0;
}
----------------------------------------------------------------------------------------struct Point
{int x;int y;
};
class cmp
{
public:bool operator()(Point& p1, Point& p2)const {if (p1.x != p2.x) {return p1.x < p2.x;} else {return p1.y < p2.y;}}
};int main()
{vector<Point> p;p.push_back(Point{ 1,2 });p.push_back(Point{ 1,3 });Point p1;p1.x = 2;p1.y = 1;p.push_back(p1);sort(p.begin(), p.end(), cmp());for (int i = 0; i < p.size(); i++) {cout << p[i].x << " " << p[i].y << endl;}/*输出:1 21 32 1*/system("pause");return 0;
}
相关文章:
![](https://img-blog.csdnimg.cn/9bd2b575066a40f7b9f7e8619b9d3732.png)
STL常用遍历,查找,算法
目录 1.遍历算法 1.1for_earch 1.2transform 2.常用查找算法 2.1find,返回值是迭代器 2.1.1查找内置数据类型 2.1.2查找自定义数据类型 2.2fin_if 按条件查找元素 2.2.1查找内置的数据类型 2.2.2查找内置数据类型 2.3查找相邻元素adjeacent_find 2.4查找指…...
![](https://www.ngui.cc/images/no-images.jpg)
BCC源码内容概览(1)
接前一篇文章:BCC源码编译和安装 本文参考官网中的Contents部分的介绍。 BCC源码根目录的文件,其中一些是同时包含C和Python的单个文件,另一些是.c和.py的成对文件,还有一些是目录。 跟踪(Tracing) exam…...
![](https://img-blog.csdnimg.cn/1ccea9bb2cfb4c8b8793e52f1401e571.png)
mysql限制用户登录失败次数,限制时间
mysql用户登录限制设置 mysql 需要进行用户登录次数限制,当使用密码登录超过 3 次认证链接失败之后,登录锁住一段时间,禁止登录这里使用的 mysql: 8.1.0 这种方式不用重启数据库. 配置: 首先进入到 mysql 命令行:然后需要安装两个插件: 在 mysql 命令行中执行: mysql> INS…...
![](https://www.ngui.cc/images/no-images.jpg)
从利用Arthas排查线上Fastjson问题到Java动态字节码技术(下)
上一篇从Arthas的源码引出了Java动态字节码技术,那么这一篇就从几种Java字节码技术出发,看看Arthas是如何通过动态字节码技术做到无侵入的源码增强; Java大部分情况下都是解释执行的,也就是解释.class文件,所以如果我们…...
![](https://img-blog.csdnimg.cn/a1179c1aff124843b9df1cd077a0c7c3.png)
Ubuntu中安装Anaconda 如何将 路径导入为全局变量
第一步:将你的anaconda 路径复制下来,在终端输入对应路径。 echo export PATH"/home/你的用户名/anaconda3/bin:$PATH" >> ~/.bashrc 第二步:在终端输入下面命令或者重启系统。 source ~/.bashrc 在对应的anaconda安装目…...
![](https://img-blog.csdnimg.cn/977a1e49aeba4ae697afaab348796da1.png)
【QT】Qt的随身笔记(持续更新...)
目录 Qt 获取当前电脑桌面的路径Qt 获取当前程序运行路径Qt 创建新的文本文件txt,并写入内容如何向QPlainTextEdit 写入内容QTimerQMessageBox的使用QLatin1StringQLayoutC在c头文件中写#include类的头文件与直接写class加类名有何区别mutable关键字前向声明 QFontQ…...
![](https://img-blog.csdnimg.cn/d660272ee9c1441dbf704ff352be2592.png)
【LeetCode-简单题】589. N 叉树的前序遍历
文章目录 题目方法一:单循环栈做法方法二:递归 题目 方法一:单循环栈做法 关键在于子节点的入栈顺序,决定了子节点的出栈顺序, 因为是前序遍历 所以压栈顺序先让右边的入栈 依次往左 这样左边的节点会在栈顶 这样下次…...
![](https://www.ngui.cc/images/no-images.jpg)
Linphone3.5.2 ARM RV1109音视频对讲开发记录
Linphone3.5.2 ARM RV1109音视频对讲开发记录 说明 这是一份事后记录,主要记录的几个核心关键点,有可能很多细节没有记上,主要是方便后面自己再找回来! 版本 3.5.2 一些原因选的是这样一个旧的版本! 新的开发最好选新一些的版…...
![](https://img-blog.csdnimg.cn/a3c7e5aebb2b4439a625503333efd43a.gif)
Unity用相机实现的镜子效果
首先登场 场景中的元素 mirror是镜子,挂着我们的脚本,Quad是一个面片。Camera是用来生成RenderTexture给面片的。里面的test1是我用来调试位置的球。 镜子size是大小,x是-2,为了反转一下贴图 相机直接可以禁用掉,用…...
![](https://img-blog.csdnimg.cn/f69c5daaa74f4ea3bb4f689ae26eec32.png)
计算机网络分类
按照覆盖范围分类 (1)个域网:通常覆盖范围在1~10m。 (2)局域网:通常覆盖范围在10m~1km。 (3)城域网:覆盖范围通常在5~50 km 。 &…...
![](https://img-blog.csdnimg.cn/8a17f9fda76241ffa192541f6fe84b69.png)
AI AIgents时代 - (三.) AutoGPT和AgentGPT
前两篇讲解了Agent的原理和组件,这节我将给大家介绍两个agent项目,给出它们的工作原理和区别,并教大家亲手尝试使用 Agents🎉 🟢 AutoGPT🤖️ 我们的老朋友,之前文章也专门写过。AutoGPT 是一…...
![](https://www.ngui.cc/images/no-images.jpg)
Jmeter接口自动化和Python接口自动化,如何选择?
选择Jmeter或Python进行接口自动化测试取决于您的具体需求和环境。以下是一些可以考虑的因素: 1. 语言熟悉度:如果您对Java更熟悉,那么Jmeter可能是更好的选择。而如果您的团队或个人对Python更熟悉,那么Python可能是更好的选择。…...
![](https://img-blog.csdnimg.cn/8bcb66a90de54d0bba412f6bd78957c0.jpeg)
Sqilte3初步教程
文章目录 安装创建数据库创建和删除表插入行数据 安装 Windows下安装,首先到下载页面,下载Windows安装软件,一般是 sqlite-dll-win32-*.zip sqlite-tools-win32-*.zip下载之后将其内容解压到同一个文件夹下,我把它们都放在了D:\…...
![](https://www.ngui.cc/images/no-images.jpg)
详解Python中的json库
目录 1. json简介2. dumps/loads3. dump/load4. jsonl格式 1. json简介 JSON(JavaScript Object Notation)是一种轻量级的数据交换格式,用于在不同应用程序之间传递数据。它是一种文本格式,易于阅读和编写,同时也易于…...
![](https://img-blog.csdnimg.cn/1dc18125f7b446d792f094e1998eebe7.png)
【Spring Boot】Spring Boot源码解读与原理剖析
这里写目录标题 前言精进Spring Boot首选读物“小册”变“大书”,彻底弄懂Spring Boot全方位配套资源,学不会来找我!技术新赛道,2023领先抢跑 前言 承载着作者的厚望,掘金爆火小册同名读物《Spring Boot源码解读与原理…...
![](https://www.ngui.cc/images/no-images.jpg)
C++学习(1)
一、C概述(了解) C在C语言的基础上添加了面向对象编程和泛型编程的支持 二、helloword程序(掌握) #define _CET_SECURE_NO_WARNINGS//在开发软件visual studio编译 c文件时, visual studio认为strcpy,scanf等函数不安全的导致报…...
![](https://img-blog.csdnimg.cn/72f3e91ea56e4661960335e2ce4cbe02.png)
机器人如何有效采摘苹果?
摘要:本文利用动捕数据构建拟人运动模型,对比观察两种苹果采摘模式,并对系统性能进行全面评估,为提高机器人采摘效率提供创新方法。 近期,一项关于苹果采摘机器人的有趣研究—— "Design and evaluation of a rob…...
![](https://img-blog.csdnimg.cn/be75f855c89749ba8651002d72333d1b.png)
C# OpenCvSharp Yolov8 Detect 目标检测
效果 项目 代码 using OpenCvSharp; using OpenCvSharp.Dnn; using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; using System.Drawing; using System.Linq; using System.Text; using System.Windows.Forms;namespace Open…...
![](https://www.ngui.cc/images/no-images.jpg)
rust数组
一、定义数组 (一)一维数组 1.指定所有元素 语法格式 let variable_name: [dataType; size] [value1,value2,value3];例如 let arr: [i32; 4] [10,20,30,40];2.指定初始值和长度 所有元素具有相同的值 语法格式 let variable_name: [dataType; siz…...
![](https://img-blog.csdnimg.cn/7cf8d15a0c8f43b5866566df00e87fd4.png)
ubuntu | 安装NVIDIA套件:驱动、CUDA、cuDNN
CUDA 查看支持最高的cuda版本 nvidia-smiCUDA Version:12.2 区官网下在12.2.x最新的版本即可CUDA Toolkit Archive | NVIDIA Developer 下载安装 wget https://developer.download.nvidia.com/compute/cuda/12.2.2/local_installers/cuda_12.2.2_535.104.05_linux.run sudo…...
![](https://www.ngui.cc/images/no-images.jpg)
JAVA学习笔记
一、学习要点 java的最大优势就是跨平台; java的三个版本,javaSE标准版本,javaEE企业版本,javaME微型版本(用的比较少); JVM(Java Virtual Machine,Java虚拟机); JRE…...
![](https://img-blog.csdnimg.cn/img_convert/a1687ac767d17c4a229fb61626e55e32.png)
车载软件架构 —— 持续集成持续交付
车载软件架构 —— 持续集成持续交付 我是穿拖鞋的汉子,魔都中坚持长期主义的汽车电子工程师。 老规矩,分享一段喜欢的文字,避免自己成为高知识低文化的工程师: 对学习而言,学习之后的思考、思考之后的行动、行动之后的改变更重要,如果不盯住内层的改变量,那么在表层投…...
![](https://www.ngui.cc/images/no-images.jpg)
c++ 二元运算符重载, 以加法为例
/* * c 二元运算符重载, 以加法为例 */ #include <stdio.h> class Complex { public: int r0; // real, 实部 int v0; //virtual, 虚部 }; // 重载加法 操作符 // 可见,c2元运算符,取其左侧为第一参数,右侧为第二参数 // 返回值可以付给新的变量 C…...
![](https://img-blog.csdnimg.cn/img_convert/1bec99dba00bf34e924f3d9f0dd3cb57.jpeg)
基于 SpringBoot+Vue的电影影城管理系统,附源码,数据库
文章目录 第一章 简介第二章 技术栈第三章 功能分析第四章 系统设计第5章 系统详细设计六 源码咨询 第一章 简介 本影城管理系统,是基于 Java SpringBoot 开发的。主要包括二大功能模块,即用户功能模块和管理员功能模块。 (1)管…...
![](https://img-blog.csdnimg.cn/img_convert/ea199c1b5d7e4a354ba8cb956b7f51dc.png)
Docker实战技巧(二):Kubernetes基础操作实战
Kubernetes定位在Saas层,重点解决了微服务大规模部署时的服务编排问题 1、关闭防火墙并设置开机禁用 systemctl stop firewalld systemctl disable firewalld 2、配置repo cd /etc/yum.repos.d/ 下载Docker repo wget https://mirrors.aliyun.com/docker-…...
![](https://img-blog.csdnimg.cn/dd5ff2337389444db742a557c5938d6f.png)
计算机视觉与深度学习-循环神经网络与注意力机制-Attention(注意力机制)-【北邮鲁鹏】
目录 引出Attention定义Attention-based model通俗解释应用在图像领域图像字幕生成(image caption generation)视频处理 序列到序列学习:输入和输出都是长度不同的序列 引出Attention 传统的机器翻译是,将“机器学习”四个字都学…...
![](https://img-blog.csdnimg.cn/af777ccf06ee4e44b1b68b9f2c7644a5.png)
Centos7安装wps无法打开及字体缺失的问题解决
在centos7上安装了最新的wps2019版本的wps-office-11.1.0.11704-1.x86_64.rpm,生成了桌面图标并信任,可以新建文件,但是软件无法打开。在终端执行如下命令,用命令行启动wps: cd /opt/kingsoft/wps-office/office6/ ./…...
![](https://www.ngui.cc/images/no-images.jpg)
华为OD机试真题-会议接待-2023年OD统一考试(B卷)
题目描述: 某组织举行会议,来了多个代表团同时到达,接待处只有一辆汽车,可以同时接待多个代表团,为了提高车辆利用率,请帮接待员计算可以坐满车的接待方案,输出方案数量。 约束: 1、一个团只能上一辆车,并且代表团人数(代表团数量小于30,每个代表团人数小于30)小于…...
![](https://img-blog.csdnimg.cn/5555a393910b4683afc3de3f9ab2a83b.png)
mysql explain学习记录
参考了公司内相关博客,实践并记录下,为后面分析并优化索引做准备。 MySQL explain命令是查看MySQL查询优化器如何执行查询的主要方法,可以很好的分析SQL语句的执行情况。 每当遇到执行慢(在业务角度)的SQL,…...
![](https://img-blog.csdnimg.cn/img_convert/1c51b5b6a38aa62c8283cc41673e4ad6.png)
电压放大电路的作用有哪些(电压放大器)
电压放大电路是电子电路中常见且重要的组件,其主要作用是将输入信号的电压放大到所需的输出电压级别,并保持输入信号的形状和准确度。电压放大电路广泛应用于各种电子设备和系统中,具有以下几个重要的作用: 信号放大:电…...
![](https://img-blog.csdnimg.cn/20210424175440517.png)
班级网站中个人简介怎么做/电脑培训
PROXMOX6.3.6 更改机器名称 参考链接 https://www.baidu.com/link?urlljbh9wHn6YRho6nxxBdbydXNZ3vDERHVZF98SqkDNxJagu4NCtTfvnz5NilOiqqs-peS57O0v5z1t7r2-Zy2dhGQ7D5oIilOM6guFO9uTIa&wd&eqida61791420001d917000000066083e127 参考这个链接准备不停机修改主机名…...
![](/images/no-images.jpg)
wordpress javaweb/宁波网站制作与推广价格
【程序 11】 题目:古典问题:有一对兔子,从出生后第 3 个月起每个月都生一对兔子,小兔子长到第三个月后每个月又生一对兔子,假如兔子都不死,问每个月的兔子总数为多少? 1.程序分析: …...
![](http://p02.5ceimg.com/content/361925f4-791d-eb11-8da9-e4434bdf6706.jpeg)
专业b2c电商网站开发/百度高级检索入口
2020年10月18日上午9:00,华东交通大学第一届“职教杯”运动会暨“中铁市政环境杯”武术太极拳比赛在cuba馆隆重举行。本次比赛一共有来自机电与车辆工程学院等15个学院代表队的领队、教练员、运动员及裁判员、工作人员共350人参加,历时一天&a…...
![](/images/no-images.jpg)
水利建设经济定额站网站/电子商务主要干什么
在多线程或单线程任务中,让线程带传入参数一直是个麻烦的问题,通常有种方法就是以类,对像的变量来传参数,这种方法理解上很简单不过在某些场合使用很麻烦,这里就不介绍了,我们主要介绍一种.NET2.0中新增加的带参数运行线程的方法,示例程序如下: ParameterizedThreadStart ParSt…...
![](/images/no-images.jpg)
网站改版 降权/提高工作效率的方法
天翼云Linux主机如何挂载数据盘天翼云Linux主机如何挂载数据盘?很多使用了天翼云主机的朋友不是很清楚,对此了解比较片面,不清楚具体的步骤有哪些?一团网小编就来为大家详细分解一下天翼云Linux主机挂载数据盘的步骤。Linux主机挂…...
![](http://upload-images.jianshu.io/upload_images/2267652-98653796211eb9aa.png?imageMogr2/auto-orient/strip%7CimageView2/2/w/700/format/webp)
专业网站建设多少钱/免费建站哪个最好
摘要: 在Web应用中,使用JWT替代session并不是个好主意适合JWT的使用场景抱歉,当了回标题党。我并不否认JWT的价值,只是它经常被误用。 什么是JWT 根据维基百科的定义,JSON WEB Token(JWT,读作 […...