CCF CSP 线性分类器 C++
线性分类器
#include
using namespace std;
struct Xian{
int x;
int y;
char kind;
}xian[1001];
int main(){
int n,m;
cin>>n>>m;
for(int i = 0; i < n;i++){
cin>>xian[i].x>>xian[i].y>>xian[i].kind;
}
int a[m][3];
int b[m] = {0};
for(int i= 0; i < m; i++){
cin>>a[i][0]>>a[i][1]>>a[i][2];
int a1 = 0,a2 = 0, b1 =0, b2= 0;
for(int j = 0 ;j < n; j++){
int sum = a[i][1]*xian[j].x + a[
共有 0 条评论