Go: package main

import (
        "fmt"
)

var paper [10][10]int

func main() {
        var x, y, s int
        for {
                _, err := fmt.Scanf("%d,%d,%d", &x, &y, &s)
                if err != nil {
                        break
                }

                fill(x, y, s)
        }
        var d, z int
        for i := 0; i < 10; i++ {
                for j := 0; j < 10; j++ {
                        if paper[i][j] == 0 {
                                z += 1
                        }
                        if paper[i][j] > d {
                                d += 1
                        }
                }
        }
        fmt.Printf("%d\n%d\n", z, d)
}

func fill(x int, y int, s int) {
        paper[x][y] += 1
        if x > 0 {
                paper[x-1][y] += 1
        }
        if x < 9 {
                paper[x+1][y] += 1
        }
        if y > 0 {
                paper[x][y-1] += 1
        }
        if y < 9 {
                paper[x][y+1] += 1
        }

        if s >= 2 {
                if x > 0 && y > 0 {
                        paper[x-1][y-1] += 1
                }
                if x > 0 && y < 9 {
                        paper[x-1][y+1] += 1
                }
                if x < 9 && y > 0 {
                        paper[x+1][y-1] += 1
                }
                if x < 9 && y < 9 {
                        paper[x+1][y+1] += 1
                }
        }

        if s > 2 {
                if x > 1 {
                        paper[x-2][y] += 1
                }
                if x < 8 {
                        paper[x+2][y] += 1
                }
                if y > 1 {
                        paper[x][y-2] += 1
                }
                if y < 8 {
                        paper[x][y+2] += 1
                }
        }
}

C++: #include<iostream>
#include<cstdio>
using namespace std;
int vx[4]={1,0,-1,0};
int vy[4]={0,1,0,-1};
int vx2[4]={2,0,-2,0};
int vy2[4]={0,2,0,-2};
int main(){
  string str;
  int x,y,s;
  int Map[10][10];
  for(int i=0;i<10;i++)
    for(int j=0;j<10;j++)
      Map[i][j]=0;
  while(cin>>str){
    x=str[0]-'0';
    y=str[2]-'0';
    s=str[4]-'0';
    switch(s){
    case 1:
      Map[x][y]++;
      for(int i=0;i<4;i++)
	if(x+vx[i]<=9&&x+vx[i]>=0&&y+vy[i]<=9&&y+vy[i]>=0)
	  Map[x+vx[i]][y+vy[i]]++;
      break;
    case 2:
      for(int i=-1;i<=1;i++){
	for(int j=-1;j<=1;j++){
	  if(x+i<=9&&x+i>=0&&y+j<=9&&y+j>=0)
	    Map[x+i][y+j]++;
	}
      }
      break;
    case 3:
      for(int i=-1;i<=1;i++){
	for(int j=-1;j<=1;j++){
	  if(x+i<=9&&x+i>=0&&y+j<=9&&y+j>=0)
	    Map[x+i][y+j]++;
	}
      }
      for(int i=0;i<4;i++)
	if(x+vx2[i]<=9&&x+vx2[i]>=0&&y+vy2[i]<=9&&y+vy2[i]>=0)
	  Map[x+vx2[i]][y+vy2[i]]++;
      break;
    }
    /* for(int i=0;i<10;i++){
      for(int j=0;j<10;j++){
	cout<<Map[i][j]<<" ";
      }
      cout<<endl;
      }*/
  }
  int white=0;
  int Max=0;
  for(int i=0;i<10;i++){
    for(int j=0;j<10;j++){
      if(Map[i][j]==0)
	white++;
      Max=max(Max,Map[i][j]);
    }
  }
  cout<<white<<endl<<Max<<endl;
  return 0;
}

C++: #define _CRT_SECURE_NO_WARNINGS
#include <stdio.h>
#include <iostream>

using namespace std;

int main(){
	int a[14][14];
	int i; int ii; int kosuu = 0; int mol = 0;
	for (i = 0; i <= 13; i++){
		for (ii = 0; ii <= 13; ii++){
			a[i][ii] = 0;
		}
	}
	int x = 0; int y = 0; int size = 0;
	while (!cin.eof()){
		scanf("%d,%d,%d", &x, &y, &size);
		int xx = x + 2; int yy = y + 2;

		if (size == 1){
			a[xx][yy] = a[xx][yy] + 1;
			a[xx+1][yy] = a[xx+1][yy] + 1;			a[xx-1][yy] = a[xx-1][yy] + 1;			a[xx][yy+1] = a[xx][yy+1] + 1;			a[xx][yy-1] = a[xx][yy-1] + 1;
		}

		if (size == 2){
			for (i = 0; i <= 2; i++){
				for (ii = 0; ii <= 2; ii++){
					a[xx + i - 1][yy + ii - 1] = a[xx + i - 1][yy + ii - 1] + 1;
				}
			}
		}

		if (size == 3){
			for (i = 0; i <= 2; i++){
				for (ii = 0; ii <= 2; ii++){
					a[xx + i - 1][yy + ii - 1] = a[xx + i - 1][yy + ii - 1] + 1;
				}
			}
			a[xx + 2][yy] = a[xx + 2][yy] + 1;			a[xx - 2][yy] = a[xx - 2][yy] + 1;			a[xx][yy + 2] = a[xx][yy + 2] + 1;			a[xx][yy - 2] = a[xx][yy - 2] + 1;
		}
		/*http://judge.u-aizu.ac.jp/onlinejudge/description.jsp?id=0026&lang=jp */
	}
	for (i = 2; i <= 11; i++){
		for (ii = 2; ii < 11; ii++){
			if (a[i][ii] == 0){
				kosuu = kosuu + 1;
			}
			if (a[i][ii] > mol){
				mol = a[i][ii];
			}
		}
	}
	cout << kosuu << endl;
	cout << mol << endl;
	return  0;
}
//14*14????????????????????§?¨???????2??????11 size?????¢??°?????????

C++: #include <iostream>
#include <algorithm>
#include <vector>
#include <cstdio>
#include <string>
#include <set>
#include <map>
#include <queue>
#include <stack>
#include <cmath>
#include <functional>
#include <numeric>
#include <iomanip>
#define fi first
#define se second
#define fcout(n) cout<<fixed<<setprecision((n))
#define cinl(str) getline(cin,(str))
using namespace std;
bool value(int y,int x,int R,int C){return 0<=y&&y<R&&0<=x&&x<C;}
typedef pair<int,int> pii;
typedef long long ll;
typedef vector<int> vi;
typedef vector<long long > vll;
typedef vector< vi > vvi;
double pie=acos(-1);
int INF=10000009;
int dx[4] = { 0,-1,0,1 };
int dy[4] = { -1,0,1,0 };
int dx2[4] = { 0,-2,0,2 };
int dy2[4] = { -2,0,2,0 };
int m[15][15];
int main() {
	int x[10000],y[10000],z[10000];
	char s,t;
	int count=0,M=0;
	int n=0;
	while(true){
		cin>>x[n]>>s>>y[n]>>t>>z[n];
		if (cin.eof())break;
		n++;
	}
	n--;
	//cout<<n<<endl;
	for(int i=0;i<=n;i++){
		if(z[i]==1){
			m[y[i]][x[i]]++;
			for(int j=0;j<4;j++){
				if(value(y[i]+dy[j],x[i]+dx[j],10,10)){
					m[y[i]+dy[j]][x[i]+dx[j]]++;
				}
			}
		}
		else if(z[i]==2){
			for(int j=-1;j<=1;j++){
				for(int k=-1;k<=1;k++){
					if(value(y[i]+k,x[i]+j,10,10)){
						m[y[i]+k][x[i]+j]++;
					}
				}
			}
		}
		else{
			for(int j=-1;j<=1;j++){
				for(int k=-1;k<=1;k++){
					if(value(y[i]+k,x[i]+j,10,10)){
						m[y[i]+k][x[i]+j]++;
					}
				}
			}
			for(int j=0;j<4;j++){
				if(value(y[i]+dy2[j],x[i]+dx2[j],10,10)){
					m[y[i]+dy2[j]][x[i]+dx2[j]]++;
				}
			}
		}
		/*for(int i=0;i<10;i++){
			for(int j=0;j<10;j++){
				cout<<m[i][j]<<" ";
			}
			cout<<endl;
		}*/
	}
	for(int i=0;i<=9;i++){
		for(int j=0;j<=9;j++){
			if(m[i][j]==0) count++;
			if(m[i][j]>M) M=m[i][j];
		}
	}
	cout<<count<<endl;
	cout<<M<<endl;
}

C++: #include<iostream>
#include<cstdio>
using namespace std;
 int map[10][10]={0};

void drop(int x,int y){
  if(x<0&&x>9&&y<0&&y>9)map[x][y]++;
  return;
}

int main(){
  int x,y,s;
 
  while(scanf("%d,%d,%d",&x,&y,&s)){
    // if(x==-1)break;
    drop(x,y);
    drop(x+1,y);
    drop(x-1,y);
    drop(x,y+1);
    drop(x,y-1);
    if(s==2||s==3){
      drop(x+1,y+1);
      drop(x+1,y-1);
      drop(x-1,y+1);
      drop(x-1,y-1);
    }
    if(s==3){
      drop(x+2,y);
      drop(x-2,y);
      drop(x,y+2);
      drop(x,y-2);
    }
  }
  int max=0;
  int white=0;
  for(int i=0;i<10;i++){
    for(int j=0;i<10;j++){
      if(map[i][j]==0)white++;
      if(map[i][j]>max)max=map[i][j];
    }
  }
  cout<<white<<endl<<max;
}

C++: #include <iostream>
#include <string>
using namespace std;




int main()
{
	int area[10][10] = {0};
	int x,nx,ny,y,size;
	int count = 0;
	int max = 0;
	char ch1,ch2;
	while(cin >> x >>ch1>> y >>ch2>> size){
		nx=x+2;
		ny=y+2;
		switch (size){
		case 3:
			area[nx-2][ny]++;
			area[nx+2][ny]++;
			area[nx][ny-2]++;
			area[nx][ny+2]++;
		case 2:
			area[nx-1][ny-1]++;
			area[nx+1][ny-1]++;
			area[nx-1][ny+1]++;
			area[nx+1][ny+1]++;
		case 1:
			area[nx-1][ny]++;
			area[nx+1][ny]++;
			area[nx][ny-1]++;
			area[nx][ny+1]++;
		}
		area[nx][ny]++;
	}

	for (int i=2;i<12;i++){
		for (int j=2;j<12;j++){
			if (area[i][j]==0){
				count++;
			}
			if(max<area[i][j]){
				max=area[i][j];
			}
		}
	}
	
	cout << count <<endl;
	cout << max << endl;


	return 0;
}