开启第二part的欧拉计划
Problem 11
#include <iostream>
#include <stdio.h>
#include <string.h>
#include <ctype.h>
#include <stdlib.h>
using namespace std;
#define ll long long
ll a[100][100];
int main()
{
ll sum=0;
memset(a,0,sizeof a);
for (int i=0; i<20; i++)
for (int j=0; j<20; j++)
scanf("%d",&a[i][j]);
for (int i=0; i<=16; i++)
for (int j=0; j<=16; j++)
{
sum =max(sum,a[i][j]*a[i+1][j+1]*a[i+2][j+2]*a[i+3][j+3]);
}
for (int i=0; i<20; i++)
for (int j=0; j<=16; j++)
{
sum = max(sum,a[i][j]*a[i][j+1]*a[i][j+2]*a[i][j+3]);
sum = max(sum,a[j][i]*a[j+1][i]*a[j+2][i]*a[j+3][i]);
}
for (int i=0; i<20;