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<stdio.h>
using namespace std;
int main(){
  int dec[10][10];
  int x,y,size,num,max;
  char a;
  for(int i=0;i<10;i++){
    for(int j=0;j<10;j++){
       dec[i][j]=0;
    }
  }
                
  while(cin >> y >> a>> x>> a>> size){
    if(size == 1){
      if(x+1 < 10 && x+1 >= 0 && y>=0 && y<10) dec[x+1][y] += 1;
      if(x-1 >=0 && x-1 < 10 && y>=0 && y<10) dec[x-1][y] += 1;
      if(x >= 0 && x < 10 && y+1<10 && y+1 >= 0) dec[x][y+1] += 1;
	 if(x >=0 && x< 10 && y-1 <10 && y-1 >=0) dec[x][y-1] += 1;
	    dec[x][y] += 1;
	    } else if(size == 2){
      for(int i=-1;i<=1;i++){
	for(int j=-1;j<=1;j++){
	  if(x+i >=0&& x+i<10 && y+j>=0&& y+j<10) dec[x+i][y+j] +=1;
	}
      }
    }else if(size==3){
      for(int i=-1;i<=1;i++){
	for(int j=-1;j<=1;j++){
	  if(x+i >=0&& x+i<10 && y+j>=0&& y+j<10)  dec[x+i][y+j] +=1;
	}
      }
      if(x+2<10 && x+2 >=0 && y>=0 && y<10  )dec[x+2][y] +=1;
      if(x-2>=0 &&x-2 <10 && y>=0 && y<10  )dec[x-2][y] +=1;
      if(x<10 && x >=0 && y+2>=0 && y+2<10  )dec[x][y+2] +=1;
      if(x>=0 && x<10 && y-2>=0 && y-2<10  )dec[x][y-2] +=1;
    }
  }
  max = dec[0][0];
  for(int i=0;i<10;i++){
    for(int j=0;j<10;j++){ 
      if(dec[i][j]==0)
	num +=1; 
      if(max < dec[i][j])
	max=dec[i][j];
    }
  }
  cout << num << endl << max<<endl;
}

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

int board[10][10];

void fill(int x, int y){
	if(0<=x && x<10 && 0<=y && y<10){
		board[y][x]++;
	}
}

int main(){
	int x, y, size;
	while(scanf("%d,%d,%d", &x, &y, &size)+1){
		if(size >= 1){ // small
			fill(x, y);
			fill(x+1, y);
			fill(x-1, y);
			fill(x, y+1);
			fill(x, y-1);
		}
		if (size >= 2) { // medium
			fill(x+1, y+1);
			fill(x+1, y-1);
			fill(x-1, y+1);
			fill(x-1, y+1);
		}
		if(size >= 3){ // large
			fill(x+2, y);
			fill(x-2, y);
			fill(x, y+2);
			fill(x, y-2);
		}
	}
	int num_zero = 0;
	int deepest = 0;
	for (int i = 0; i < 10; i++) {
		for (int j = 0; j < 10; j++) {
			if(board[j][i] == 0){
				num_zero++;
			}
			if(deepest < board[j][i]){
				deepest = board[j][i];
			}
		}
	}
	cout << num_zero << endl;
	cout << deepest << endl;

	return 0;
}

C++: #include<iostream>

using namespace std;

int main(void)
{
	int paper[30][30]={};
	int x,y,size;
	char c;
	while(cin>>x>>c>>y>>c>>size)
	{
		x+=10;
		y+=10;
		if(size>=1)
		{
			paper[x][y]++;
			paper[x+1][y]++;
			paper[x-1][y]++;
			paper[x][y+1]++;
			paper[x][y-1]++;
		}
		if(size>=2)
		{
			paper[x-1][y-1]++;
			paper[x-1][y+1]++;
			paper[x+1][y-1]++;
			paper[x+1][y+1]++;
		}
		if(size>=3)
		{
			paper[x+2][y]++;
			paper[x-2][y]++;
			paper[x][y+2]++;
			paper[x][y-2]++;
		}
	}
	int white,max;
	white=max=0;
	for(int i=10;i<20;i++){
		for(int j=10;j<20;j++){
			if(paper[i][j]==0)white++;
			else if(paper[i][j]>max)max=paper[i][j];
		}
	}
	cout<<white<<endl<<max<<endl;
}

C++: #include <bits/stdc++.h>
using namespace std;

/* {{{ */
#define PI(N) ((M_PI * (N)) / 180) //?§???????????????¢??????????????????
#define CL(N) (cout << (N) << endl)
#define DCT(N) (cout << "debug " << (N) << endl)
#define REP(i, N) for (int i = 0; i < (N); i++)
/* }}} */

int dx[] = {1, 0, -1, 0}, dy[] = {0, 1, 0, -1};
int seet[10][10];

void ink(int y, int x)
{
    if (0 <= y && y < 10 && 0 <= x && x < 10) seet[y][x]++;
}

int main()
{
    int x, y, s, zero = 0, m = 0;

    while (scanf("%d,%d,%d", &x, &y, &s) != EOF){

        if (1 <= s){
            ink(y, x);
            REP(i, 4){
                ink(y + dy[i], x + dx[i]);
            }
        }
        if (2 <= s){
           ink(y - 1, x - 1);
           ink(y - 1, x + 1);
           ink(y + 1, x - 1);
           ink(y + 1, x + 1);
        }
        if (3 == s){
            REP(i, 4){
                ink(y + (dy[i] * 2), x + (dx[i] * 2));
            }
        }
    }

    REP(i, 10){
        REP(j, 10){
            if (seet[i][j] == 0){
                zero++;
            }
            m = max(m, seet[i][j]);
        }
    }

    CL(zero);
    CL(m);

    return (0);
}

C++: #include <iostream>
#include <cstdio>
#include <vector>
#include <algorithm>
using namespace std;

int main(){
	vector<vector<int> > field(12, vector<int>(12, 0));
	int x,y,s;
	while(scanf("%d,%d,%d", &x, &y, &s)!=EOF){
		x++; y++;
		for(int i=-2; i<=2; i++){
			for(int j=-2; j<=2; j++){
				if(s==1 && abs(i)+abs(j)<=1){
					field[x+i][y+j]++;
				}
				if(s==2 && abs(i)<=1 && abs(j)<=1){
					field[x+i][y+j]++;
				}
				if(s==3 && abs(i)+abs(j)<=2){
					field[x+i][y+j]++;
				}
			}
		}
	}
	
	int white = 0;
	int deep = 0;
	for(int i=1; i<=10; i++){
		for(int j=1; j<=10; j++){
			deep = max(deep, field[i][j]);
			if(field[i][j] == 0 ) white++;
		}
	}
	cout << white << endl << deep << endl; 
    return 0;
}

C++: #include <iostream>
#include <string>
#include <algorithm>
#include <math.h>
#include <vector>
#include <set>

using namespace std;
typedef long long LL;
static const double EPS = 1e-9;

#define FOR(i,k,n) for (int i=(k); i<(int)(n); ++i)
#define REP(i,n) FOR(i,0,n) 

const static int dx[13] = {0,1,0,-1,0,1,-1,-1,1,2,0,-2,0};
const static int dy[13] = {0,0,1,0,-1,1,1,-1,-1,0,2,0,-2};
int main(void){  
  int date[14][14]={0};
  int x,y,s,c=0,m=0;
  
  while(scanf("%d,%d,%d",&x,&y,&s) != EOF)
    REP(i,4*s+1) date[x+2+dx[i]][y+2+dy[i]] += 1;

  FOR(i,2,12)
    FOR(j,2,12){
      if(date[i][j]==0) c++;
      m = max(date[i][j], m);
    }
  cout << c << endl;
  cout << m << endl;
}