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 <cstdio>
#include <cstdlib>
#define rep(i, n) for(int i = 0; i < (n); ++i)

int p[11][11];
int main()
{
	int dx[] = { -1, 0, 0, 1, -1, -1, 1, 1, -2, 0, 0, 2 };
	int dy[] = { 0, -1, 1, 0, -1, 1, -1, 1, 0, -2, 2, 0 };
	int x, y, s;
	rep(i, 10) rep(j, 10) p[i][j] = 0;
	while (scanf("%d,%d,%d", &x, &y, &s) == 3) {
		p[y][x]++;
		rep(i, 4 * s) {
			int r = y + dy[i];
			int c = x + dx[i];
			if (r < 0 || r > 11 || c < 0 || c > 11) continue;
			p[r][c]++;
		}
	}
	int c = 0, best = 0;
	rep(i, 10) rep(j, 10) {
		if (p[i][j] == 0) c++;
		if (best < p[i][j]) best = p[i][j];
	}
	printf("%d\n%d\n", c, best);
	return 0;
}

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

int main(){
	int x, y, p, pt;
	string str;
	int field[10][10];
	int res_M, res_zero;
	
	for(int i = 0; i < 10; i++){
		for(int j = 0; j < 10; j++){
			field[i][j] = 0;
		}
	}
	
	while(getline(cin, str)){
		x = 0; y = 0; p = 0;
		pt = 0;
		
		while(pt < str.size() && str[pt] != ','){
			x = x * 10 + (str[pt] - 48);
			pt++;
		}
		pt++;
		while(pt < str.size() && str[pt] != ','){
			y = y * 10 + (str[pt] - 48);
			pt++;
		}
		pt++;
		while(pt < str.size() && str[pt] != ','){
			p = p * 10 + (str[pt] - 48);
			pt++;
		}
		
		//1st
		field[y][x]++;
		if(y > 0) field[y - 1][x]++;
		if(x > 0) field[y][x - 1]++;
		if(y + 1 < 10) field[y + 1][x]++;
		if(x + 1 < 10) field[y][x + 1]++;
		p--;
		if(p > 0){
			//2nd
			if(x > 0 && y > 0) field[y - 1][x - 1]++;
			if(x + 1 < 10 && y > 0) field[y - 1][x + 1]++;
			if(x > 0 && y + 1 < 10) field[y + 1][x - 1]++;
			if(x + 1 < 10 && y + 1 < 10) field[y + 1][x + 1]++;
			p--;
		}
		if(p > 0){
			//3rd
			if(x - 2 >= 0) field[y][x - 2]++;
			if(x + 2 < 10) field[y][x + 2]++;
			if(y + 2 < 10) field[y + 2][x]++;
			if(y - 2 >= 0) field[y - 2][x]++;
		}
	}
	
	res_M = 0; res_zero = 0;
	for(int i = 0; i < 10; i++){
		for(int j = 0; j < 10; j++){
			if(field[i][j] == 0) res_zero++;
			else res_M = max(res_M, field[i][j]);
		}
	}
	
	cout << res_zero << endl << res_M << endl;
	
	return 0;
}

C++: #include<iostream>
#include<cstdio>
using namespace std;
int main(){
  int field[15][15] = {0};
  for(;;){
    int x,y,s;
    if(scanf("%d,%d,%d",&x,&y,&s) == EOF) break;
    field[x+2][y+2]++;
    field[x+1][y+2]++;
    field[x+2][y+1]++;
    field[x+3][y+2]++;
    field[x+2][y+3]++;
    if(s>1){
      field[x+1][y+1]++;
      field[x+3][y+3]++;
      field[x+1][y+3]++;
      field[x+3][y+1]++;
    }
    if(s>2){
      field[x][y+2]++;
      field[x+2][y]++;
      field[x+4][y+2]++;
      field[x+2][y+4]++;
    }
  }
  int ans[2] = {0};
  for(int i=2; i<12; i++){
    for(int j=2; j<12;j++){
      if(field[i][j] == 0) ans[0]++;
      if(ans[1]<field[i][j]) ans[1] = field[i][j];
    }
  }
  cout <<ans[0]<<endl<<ans[1]<<endl;
  return 0;
}

C++: #include <iostream>
#include <iomanip>
#include <list>
#include <map>
#include <algorithm>
#include <stack>
#include <string>
#include <vector>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <cmath>

#define DEBUG 0

using namespace std;

struct INKI{
	int x;
	int y;
	int size;
};

int main(){
	int map[10][10];

	for(int i = 0; i < 10; i++){
		for(int j = 0; j < 10; j++){
			map[i][j] = 0;
		}
	}

	INKI tmp;
	while( scanf("%d,%d,%d", &tmp.x, &tmp.y, &tmp.size) ){
		if(tmp.size == 3){
			for(int i = -2; i <= 2; i++){
				if(tmp.y + i >= 0 && tmp.y + i < 10){
					map[tmp.y + i][tmp.x]++;
				}
				if(tmp.x + i >= 0 && tmp.x + i < 10){
					map[tmp.y][tmp.x + i]++;
				}
			}
			map[tmp.y][tmp.x]--;
			for(int i = -1; i <= 1; i += 2){
				if(tmp.y + i >= 0 && tmp.y + i < 10){
					for(int j = -1; j <= 1; j += 2){
						if(tmp.x + j >= 0 && tmp.x + j < 10){
							map[tmp.y + i][tmp.x + j]++;
						}
					}
				}
			}
		}
		else if(tmp.size == 2){
			for(int i = tmp.y - 1; i <= tmp.y + 1; i++){
				if(i >= 0 && i < 10){
					for(int j = tmp.x - 1; j <= tmp.x + 1; j++){
						if(j >= 0 && j < 10){
							map[i][j]++;
						}
					}
				}
			}
		}
		else if(tmp.size == 1){
			for(int i = -1; i <= 1; i++){
				if(tmp.y + i >= 0 && tmp.y + i < 10){
					map[tmp.y + i][tmp.x]++;
				}
				if(tmp.x + i >= 0 && tmp.x + i < 10){
					map[tmp.y][tmp.x + i]++;
				}
			}
			map[tmp.y][tmp.x]--;
		}
#if DEBUG
		for(int i = 0; i < 10; i++){
			for(int j = 0; j < 10; j++){
				if(j){
					cout << " ";
				}
				cout << map[i][j];
			}
			cout << endl;
		}
#endif


	}

	int noColor = 0;
	int koi = 0;

	for(int i = 0; i < 10; i++){
		for(int j = 0; j < 10; j++){
			if(map[i][j] == 0){
				noColor++;
			}
			if(koi < map[i][j]){
				koi = map[i][j];
			}
		}
	}

	cout << noColor << endl;
	cout << koi << endl;

	return 0;
}

C++: #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()){
		cin >> 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?????¢??°?????????