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>
#include <vector>
#include <list>
#include <algorithm>
#include <cmath>
#include <stack>
#include <set>
using namespace std;

#define REP(i,n) for(int (i)=0; (i)<(n); (i)++)
#define FOR(i,a,b) for(int (i)=(a); (i)<(b); (i)++)
#define PUSH(n,v) for(int i=0; i<(n); i++) {int j; cin >> j; v.push_back(j);}
#define ALL(v) v.begin(), v.end()

vector<vector<int>> vv;

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

void big(int x, int y) {
    ink(x-2,y);
    ink(x-1,y);
    ink(x,y);
    ink(x+1,y);
    ink(x+2,y);
    ink(x-1,y-1);
    ink(x,y-1);
    ink(x+1,y-1);
    ink(x-1,y+1);
    ink(x,y+1);
    ink(x+1,y+1);
    ink(x,y-2);
    ink(x,y+2);
}

void mid(int x, int y) {
    ink(x-1,y);
    ink(x,y);
    ink(x+1,y);
    ink(x-1,y-1);
    ink(x,y-1);
    ink(x+1,y-1);
    ink(x-1,y+1);
    ink(x,y+1);
    ink(x+1,y+1);
}

void small(int x, int y) {
    ink(x-1,y);
    ink(x,y);
    ink(x+1,y);
    ink(x,y-1);
    ink(x,y+1);
}

int countBlank() {
    int cnt = 0;
    REP(i,10) REP(j,10) if (vv[i][j] == 0) cnt++;
    return cnt;
}

int getThickest() {
    int t = 0;
    REP(i,10) REP(j,10) if (vv[i][j] > t) t = vv[i][j];
    return t;
}

int main() {
    REP(i,10) {
        vector<int> v(10,0);
        vv.push_back(v);
    }
    
    int x, y, s;
    string t;
    while(cin >> t) {
        x = t[0] - '0';
        y = t[2] - '0';
        s = t[4] - '0';
        switch (s) {
            case 1:
                small(x,y);
                break;
            case 2:
                mid(x,y);
                break;
            case 3:
                big(x,y);
                break;
                
            default:
                break;
        }
    }
    
    cout << countBlank() << endl << getThickest() << endl;
    
    return 0;
}

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

int main(){
	int x1[4] = {-1,0,0,1}, y1[4] = {0,1,-1,0};
	int x2[4] = {-1,-1,1,1}, y2[4] = {-1,1,-1,1};
	int x3[4] = {-2,0,0,2}, y3[4] = {0,-2,2,0};
	int p[10][10], x, y, s, nx, ny, maxl = 0, count = 0;
	for(int i = 0;i < 10;i++)
		for(int j = 0;j < 10;j++)p[i][j] = 0;
	char c;
	while(cin >> x >> c >> y >> c >> s){
		p[y][x]++;
		for(int i = 0;i < 4;i++){
			nx = x + x1[i];ny = y + y1[i];
			if(nx>=0&&nx<10&&ny>=0&&ny<10)p[ny][nx]++;
		}
		if(s > 1){
			for(int i = 0;i < 4;i++){
				nx = x + x2[i];ny = y + y2[i];
				if(nx>=0&&nx<10&&ny>=0&&ny<10)p[ny][nx]++;
			}
			if(s == 3){
				for(int i = 0;i < 4;i++){
					nx = x + x3[i];ny = y + y3[i];
					if(nx>=0&&nx<10&&ny>=0&&ny<10)p[ny][nx]++;
				}
			}
		}
	}
	for(int i = 0;i < 10;i++){
		for(int j = 0;j < 10;j++){
			maxl = max(maxl, p[i][j]);
			if(!p[i][j])count++;
		}
	}
	cout << count << endl << maxl << endl;
	return 0; 
}

C++: #include <iostream>
#include <cstdio>
#include <algorithm>
using namespace std;
int field[10][10];
int sx[]={-1,0,0,0,1},sy[]={0,-1,0,1,0};
int bx[]={-2,-1,-1,-1,0,0,0,0,0,1,1,1,2},by[]={0,-1,0,1,-2,-1,0,1,2,-1,0,1,0};
void small(int x,int y){
	for(int i=0;i<5;i++){
		field[x+sx][y+sy]++;
	}
}
void middle(int x,int y){
	for(int i=-1;i<=1;i++){
		for(int j=-1;j<=1;j++){
			field[x+i][y+j]++;
}
void big(int x,int y){
	for(int i=0;i<13;i++){
		field[x+bx][y+by]++;
	}
} 
int main(){
	int x,y,size,ans=0,count=0;
	for(int i=0;i<10;i++){
		for(int j=0;j<10;j++){
			field[i][j]=0;
		}
	}
	while(cin>>x>>y>>size){
		if(size==1)small(x,y);
		else if(size==2)middle(x,y);
		else big(x,y);
	}
	for(int i=0;i<10;i++){
		for(int j=0;j<10;j++){
			if(field[i][j]==0)count++;
			else ans=max(ans,field[i][j]);
		}
	}
	cout<<count<<endl<<ans<<endl;
	return 0;
}