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<stdio.h>
#include<string.h>

int main(){
	int kami[14][14],x,y,size,i,j,max,siro;
	memset(kami,0,sizeof(kami));
	
	while(0<=scanf("%d,%d,%d",&x,&y,&size)){
		if(size==1){
			kami[x+1][y+2]+=1;
			kami[x+2][y+1]+=1;
			kami[x+2][y+2]+=1;
			kami[x+2][y+3]+=1;
			kami[x+3][y+2]+=1;
		}else if(size==2){
			kami[x+1][y+1]+=1;
			kami[x+1][y+2]+=1;
			kami[x+1][y+3]+=1;
			kami[x+2][y+1]+=1;
			kami[x+2][y+2]+=1;
			kami[x+2][y+3]+=1;
			kami[x+3][y+1]+=1;
			kami[x+3][y+2]+=1;
			kami[x+3][y+3]+=1;
		}else if(size==3){
			kami[x][y+2]+=1;
			kami[x+1][y+1]+=1;
			kami[x+1][y+2]+=1;
			kami[x+1][y+3]+=1;
			kami[x+2][y]+=1;
			kami[x+2][y+1]+=1;
			kami[x+2][y+2]+=1;
			kami[x+2][y+3]+=1;
			kami[x+2][y+4]+=1;
			kami[x+3][y+1]+=1;
			kami[x+3][y+2]+=1;
			kami[x+3][y+3]+=1;
			kami[x+4][y+2]+=1;
		}
		
	}
	max=0;
	siro=0;
	
	for(i=2;i<12;i++){
		for(j=2;j<12;j++){
			if(kami[i][j]==0)++siro;
			if(max<kami[i][j])max=kami[i][j];
		}
	}
	printf("%d\n%d\n",siro,max);
	return 0;
}

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

int board[10][10];
int empty = 0;
int _max = INT_MIN;

bool ok(int val) {
    return(val >= 0 && val < 10);
}
void initialize() {
    for(int r = 0; r < 10; r++) {
        memset(board[r], 0, sizeof(board[r]));
    }
}
void small(int x, int y) {
    board[y][x]++;
    int north = y - 1, south = y + 1,  east = x + 1, west = x - 1;
    if(ok(north)) board[north][x]++;
    if(ok(south)) board[south][x]++;
    if(ok(east))  board[y][east]++;
    if(ok(west))  board[y][west]++;
}
void mid(int x, int y) {
    small(x, y);
    int uprightx = x + 1, uprighty = y + 1;
    int downrightx = x + 1, downrighty = y - 1;
    int downleftx = x - 1, downlefty = y - 1;
    int upleftx = x - 1, uplefty = y + 1;
    if(ok(uprightx) && ok(uprighty)) board[uprighty][uprightx]++;
    if(ok(downrightx) && ok(downrighty)) board[downrighty][downrightx]++;
    if(ok(downleftx) && ok(downlefty)) board[downrighty][downrightx]++;
    if(ok(upleftx) && ok(uplefty)) board[uplefty][upleftx]++;
}
void large(int x, int y) {
    mid(x, y);
    int north = y - 2, south = y + 2,  east = x + 2, west = x - 2;
    if(ok(north)) board[north][x]++;
    if(ok(south)) board[south][x]++;
    if(ok(east))  board[y][east]++;
    if(ok(west))  board[y][west]++;
}
void search() {
    for(int r = 0; r < 10; r++) {
        for(int c = 0; c < 10; c++) {
            if(board[r][c] > _max) _max = board[r][c];
            if(board[r][c] == 0) empty++;
        }
    }
}

int main(void) {
    int x, y, size;
    initialize();
    while(scanf("%d,%d,%d", &x, &y, &size) != EOF) {
        switch(size) {
            case 1: small(x, y); break;
            case 2: mid(x, y);   break;
            default:large(x, y); break;
        }
    }
    search();
    cout << empty << endl << _max << endl;
    return(0);
}

C++: #include <cstdio>
#define MAX 10

using namespace std;

int map[MAX][MAX] = {0};

const int def1[4][2] = {
  {1, 0},
  {-1, 0},
  {0, 1},
  {0, -1}
};

const int def2[8][2] = {
  {1, 0}, {-1, 0},
  {0, 1}, {0, -1},
  {1, 1}, {1, -1},
  {-1, 1}, {-1, -1}
};

const int def3[12][2] = {
  {1, 0}, {2, 0}, {-1, 0},
  {-2, 0}, {1, 1}, {0, 1},
  {-1, 1}, {1, -1}, {0, -1},
  {-1, -1}, {0, 2}, {0, -2}
};

void dodrop(int px, int py, const int d[][2], int size) {
  int x, y, i;
  for (i = 0; i < size; i++) {
    x = px + d[i][0];
    y = py + d[i][1];
    if (x < MAX && x >= 0 && y < MAX && y >= 0)
      map[x][y] += 1;
  }
  return;
}

void drop(int *p, int size) {
  if (size == 1)
    dodrop(p[0], p[1], def1, 4);
  if (size == 2)
    dodrop(p[0], p[1], def2, 8);
  if (size == 3)
    dodrop(p[0], p[1], def3, 12);
  return;
}

int main() {
  int p[2], size, sum, max;
  char c1, c2;
  while (scanf("%d,%d,%d", &p[0], &p[1], &size) != EOF) {
    drop(p, size);
    for (int i = sum = max = 0; i < MAX; i++) {
      for (int j = 0; j < MAX; j++) {
        if (map[i][j] == 0) sum++;
        if (map[i][j] > max) max = map[i][j];
      }
    }
  }
  printf("%d\n%d\n", sum, max);
  return 0;
}

C++: #include<stdio.h>

int main()
{
	int x,y,size;
	int a[14][14]={0};
	while(scanf("%d,%d,%d",&x,&y,&size)!=EOF)
	{
		if(x>=10||x<0||y>=10||y<0||size>3||size<=0)
		{
		}
		else
		{
			x+=2;
			y+=2;
			if(size==1)
			{
				a[x][y]++;
				a[x][y+1]++;
				a[x][y-1]++;
				a[x+1][y]++;
				a[x-1][y]++;
			}
			else if(size==2)
			{
				int n,m;
				n=x-1;
				for(n;n<=x+1;n++)
				{
					m=y-1;
					for(m;m<=y+1;m++)
					{
						a[n][m]++;
					}
				}
			}
			else if(size==3)
			{
				int n,m;

				a[x][y+2]++;
				a[x][y-2]++;
				a[x+2][y]++;
				a[x-2][y]++;

				n=x-1;
				for(n;n<=x+1;n++)
				{
					m=y-1;
					for(m;m<=y+1;m++)
					{
						a[n][m]++;
					}
				}
			}
		}
	}

	int zero=0,max=0;
	for(x=2;x<12;x++)
	{
		for(y=2;y<12;y++)
		{
			if(a[x][y]==0)
			{
				zero++;
			}
			if(a[x][y]>max)
			{
				max=a[x][y];
			}
		}
	}
	printf("%d\n%d\n",zero,max);
	return 0;
}

C++: #include<iostream>
#include<cstdio>
#include<algorithm>

using namespace std;

int main(){
	int masu[10][10] = {0};
	int x, y, s, i, j, n = 0, cut = 0;
	int num[100] = {0};

	while(scanf("%d,%d,%d", &x, &y, &s) != EOF){
		masu[x][y] ++;
		if(s == 1){
			masu[x][y-1] += 1, masu[x][y+1] += 1, masu[x-1][y] += 1, masu[x+1][y] += 1;
		}
		else if(s == 2){
			masu[x][y-1] += 1, masu[x][y+1] += 1, masu[x-1][y] += 1, masu[x+1][y] += 1;
			masu[x-1][y-1] += 1, masu[x+1][y-1] += 1, masu[x-1][y+1] += 1, masu[x-1][y+1] += 1;
		}
		else{
			masu[x][y-1] += 1, masu[x][y+1] += 1, masu[x-1][y] += 1, masu[x+1][y] += 1;
			masu[x-1][y-1] += 1, masu[x+1][y-1] += 1, masu[x-1][y+1] += 1, masu[x-1][y+1] += 1;
			masu[x-2][y] += 1, masu[x+2][y] += 1, masu[x][y+2] += 1, masu[x][y-2] += 1;
		}
		
	}

	for(i = 0; i < 10; i ++){
		for(j = 0; j < 10; j ++){
			num[n] = masu[i][j];
			n ++;
		}
	}

	sort(num, num+100);

	for(i =0; i < 100; i ++){
		if(num[i] == 0) cut ++;
		else break;
	}

	cout << cut - 1 << endl << num[99] << endl;

	return 0;    
}