10 2022 档案
摘要:题意 https://www.luogu.com.cn/problem/P2034 给出 个正整数 。可以选一些数,但不能有超过 个连续的数字被选择。请求出选出的数的最大值。 题目分析 看到题面,第一眼是想到这种题: 给出 个正整数 $a_1 \
阅读全文
摘要:map是个非常好用的STL 小面会演示map的几个函数 一、赋值与查询 #include <bits/stdc++.h> using namespace std; map<int,int>mp; int main(){ //赋值 mp[1]=1; mp[2]=4; mp[3]=9; //查询 pri
阅读全文