2024年8月27日

摘要: include <bits/stdc++.h> typedef long long ll; using namespace std; int main () { int n,N,a[210],i,sum=0; cin>>n>>N; a[0]=0; for(i=1;i<=n;i++){ cin>>a[ 阅读全文
posted @ 2024-08-27 11:33 lkhshnu 阅读(22) 评论(0) 推荐(0)
 
摘要: a数组记录距离平方值,其最大为2000的平方,不超int。 b数组记录3个距离最小的坐标。 ans记录下标。 每次选出一个坐标后其距离置为最大值。 include <bits/stdc++.h> typedef long long ll; using namespace std; int main 阅读全文
posted @ 2024-08-27 10:46 lkhshnu 阅读(16) 评论(0) 推荐(0)