提交后得100分的C++程序如下:
#include<iostream>
#include<string>
#include<cstring>
#include<vector>
#include<algorithm>
#include<list>
using namespace std;
int pow[]={128,64,32,16,8,4,2,1};
struct ip
{
string adress,adress1;
int len;
bool operator<(const ip &s) const
{
if(adress1==s.adress1) return len<s.len;
else return adress1<s.adress1;
}
};
bool check(string p,string q,int l