摘要:
代码先放上! 试题描述: 地图上有 n 个城市,一只奶牛要从 1 号城市开始依次经过这些城市,最终到达 n 号城市。但是这只奶牛觉得这样太无聊了,所以它决定跳过其中的一个城市(但是不能跳过 1 号和 n 号城市),使得它从1号城市开始,到达 n 号城市所经过的总距离最小。假设每一个城市 i 都有一个 阅读全文
摘要:
#include #include #include #include using namespace std; int n,m,dx[100],dy[100],q[400][2501]; int front =1,rear=1; bool a[10000][1000]; char c; int j,i,sum=0,ans=0,s,x,y,k; int main() { cin>>n>>... 阅读全文