361
  • 2024-08-17AtCoder Beginner Contest 361
    ABC361A-Insert题目传送门代码(签到题)#include<iostream>#include<string>#include<algorithm>usingnamespacestd;intn,m,x,a[111];intmain(){ cin>>n>>m>>x; for(inti=1;i<=n;++i)cin>>a[i]; for(inti=1;i&l
  • 2024-07-07AtCoder Beginner Contest 361
    AtCoderBeginnerContest361A-Insert给定一个长度为\(N\)的序列\(A\),现在希望将数字\(X\)插入到序列的第\(K\)个数字后面,变成一个新的序列\(B\)。输出序列\(B\)。\(K,N,A_i,X\le100\)模拟题。先读入\(N,K,X\)。接着在读入\(A\)的过程中一遍读入一遍输出,如果读到了第\(K
  • 2024-07-07AtCoder Beginner Contest 361)
    推荐个C++编程仓库模板https://github.com/yxc-s/programming-templateA-Insertvoidsolve(){ intn,k,x; cin>>n>>k>>x; vector<int>a(n); for(auto&x:a){ cin>>x; } a.insert(a.begin()+k,x); for(inti=0;