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<iostream>
#include<algorithm>
using namespace std;
void small_size(void);
void middle_size(void);
void big_size(void);
void solve(void);

int x,y,size;
int paper[14][14]={0};

int main(){

  while(scanf("%d,%d,%d",&x,&y,&size)!=EOF){
    switch(size){
    case 1:
      small_size();
      break;
    case 2:
      small_size();
      middle_size();
      break;
    case 3:
      small_size();
      middle_size();
      big_size();
      break;
    }

  }

  solve();

  return 0;
}

void small_size(){

  paper[y+2][x+2]++;
  paper[y+1][x+2]++;
  paper[y+2][x+1]++;
  paper[y+2][x+3]++;
  paper[y+3][x+2]++;

}
void middle_size(){

  paper[y+1][x+1]++;
  paper[y+3][x+1]++;
  paper[y+1][x+3]++;
  paper[y+3][x+3]++;

}

void big_size(){

  paper[y+2][x]++;
  paper[y][x+2]++;
  paper[y+2][x+4]++;
  paper[y+4][x+2]++;

}

void solve(){

  int i,j;
  int zero_cnt=0;
  int max=0;

  for(i=2;i<12;i++){
    for(j=2;j<12;j++){

      if(paper[i][j]==0){
	zero_cnt++;
      }

      if(max<paper[i][j]){
	max=paper[i][j];
      }
    }
  }

  printf("%d\n%d\n",zero_cnt,max);

}

C++: #include<iostream>
#include <fstream>
#include <stdio.h>
#include <stdlib.h>
#define _USE_MATH_DEFINES
#include <math.h>
#include<string>
#include<vector>
#include<cmath>
#include<stack>
#include<queue>
#include<sstream>
#include<algorithm>
#include<map>
#include<complex>
using namespace std;


#define li			long long int
#define rep(i,to)	for(int i=0;i<((int)(to));i++)
#define repp(i,start,to)	for(int i=(int)(start);i<((int)(to));i++)
#define pb			push_back
#define sz(v)		((li)(v).size())
#define bgn(v)		((v).begin())
#define eend(v)		((v).end())
#define allof(v)	(v).begin(), (v).end()
#define dodp(v,n)		memset(v,(li)n,sizeof(v))
#define bit(n)		(1ll<<(li)(n))
#define mp(a,b)		make_pair(a,b)
#define rin	rep(i,n)
#define EPS 1e-10
#define ETOL 1e-8
#define MOD 1000000007
#define F first
#define S second
#define p2(a,b)		cout<<a<<"\t"<<b<<endl
#define p3(a,b,c)		cout<<a<<"\t"<<b<<"\t"<<c<<endl

int main(){
	li dx[13]={ 0, -1,  1,  0,  0,  1,  1, -1, -1,  2, -2,  0,  0};
	li dy[13]={ 0,  0,  0, -1,  1,  1, -1,  1, -1,  0,  0,  2, -2};
	li lim[3]={ 5, 9, 13};
	
	li kami[10][10];
	rep(i,10)rep(j,10)kami[i][j]=0;
	
	int x,y,s;
	while(scanf(" %d,%d,%d", &x, &y, &s)){
		rep(i,lim[s-1]){
			li nx=x+dx[i];
			li ny=y+dy[i];
			if(min(nx,ny)>=0 && max(nx,ny)<10)kami[nx][ny]++;
		}
		
	}
	
	li siro=0;
	li ma=0;
	
	rep(i,10){
		rep(j,10){
			ma=max(ma,kami[i][j]);
			if(kami[i][j]==0)siro++;
		}
	}
	cout<<siro<<endl<<ma<<endl;
	
	return 0;
}

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

const int dx[] = {0, 0, 0, 1, -1, 1, 1, -1, -1, -2, 2, 0, 0};
const int dy[] = {0, 1, -1, 0, 0, 1, -1, 1, -1, 0, 0, -2, 2};

int main()
{
	int xy[10][10] = {0};
	int x,y,size;
	
	while(scanf("%d,%d,%d", &x,&y,&size) != EOF){
		if (size < 4){
			for (int d = 0; d < 1 + size * 4; d++){
				int nx, ny;
				nx = x + dx[d];
				ny = y + dy[d];
				if (nx >= 0 && nx < 10 && ny >= 0 && ny < 10){
					xy[nx][ny] += 1;
				}
			}
		}
	}
	int w=0,con = 0;
	
	for(int i=0; i < 10; i++){
		for(int j=0; j < 10; j++){
			if(xy[i][j] == 0)w++;
			if(con < xy[i][j])con = xy[i][j];
		}
	}
	
	printf("%d\n%d\n", w, con);

	return (0);
}

C++: #include <iostream>
#define MAX_N 10
#define MAX_M 10
using namespace std;

int field[MAX_N][MAX_M] = {0};
int x, y, size, nx, ny;

void Big()
{
	int mx[13] = {-1, -1, -1, 0, 0, 0, 1, 1, 1, -2, 0, 0, 2}, my[13] = {-1, 0, 1, -1, 0, 1, -1, 0, 1, 0, -2, 2, 0};
	for (int i = 0; i < 9; i++) {
		nx = x + mx[i]; ny = y + my[i];
		if (0 <= nx && nx < MAX_N && 0 <= ny && ny < MAX_M) field[nx][ny]++; 
	}
}

void Midole()
{
	int mx[9] = {-1, -1, -1, 0, 0, 0, 1, 1, 1}, my[9] = {-1, 0, 1, -1, 0, 1, -1, 0, 1};
	for (int i = 0; i < 9; i++) {
		nx = x + mx[i]; ny = y + my[i];
		if (0 <= nx && nx < MAX_N && 0 <= ny && ny < MAX_M) field[nx][ny]++; 
	}
}

void Mini()
{
	int mx[5] = {-1, 0, 0, 0, 1}, my[5] = {0, -1, 0, 1, 0};
	for (int i = 0; i < 5; i++) {
		nx = x + mx[i]; ny = y + my[i];
		if (0 <= nx && nx < MAX_N && 0 <= ny && ny < MAX_M) field[nx][ny]++; 
	}
}

int main(void)
{
	int ans = 0, color = 0;
	while (cin >> x >> y >> size) {
		switch (size) {
			case 1: Mini(); break;
			case 2: Midole(); break;
			case 3: Big(); break;
		}
	}
	for (int i = 0; i < 10; i++) {
		for (int j = 0; j < 10; j++) {
			if (field[i][j] == 0) ans++;
			else if (color < field[i][j]) color = field[i][j];
		}
	}
	cout << ans << endl << color << endl;

	return 0;
}

C++: #include<iostream>

using namespace std;

bool check(int x, int y) {
	if (x >= 0 && x <= 9 && y >= 0 && y <= 9) {
		return true;
	}
	else {
		return false;
	}
}


int main() {
	int paper[10][10] = { 0 };
	int x, y, s;
	char d, h;
	while (cin >> x >> d >> y >> h >> s) {
		if (check(x, y)) {
			paper[x][y] += 1;
		}
		if (check(x - 1, y)) {
			paper[x - 1][y] += 1;
		}
		if (check(x + 1, y)) {
			paper[x + 1][y] += 1;
		}
		if (check(x, y - 1)) {
			paper[x][y - 1] += 1;
		}
		if (check(x, y + 1)) {
			paper[x][y + 1] += 1;
		}

		if (s != 1) {
			if (check(x-1,y-1)) {
				paper[x - 1][y - 1] += 1;
			}
			if (check(x - 1, y + 1)) {
				paper[x - 1][y + 1] += 1;
			}
			if (check(x + 1, y - 1)) {
				paper[x + 1][y - 1] += 1;
			}
			if (check(x + 1, y + 1)) {
				paper[x + 1][y + 1] += 1;
			}
		}

		if (s == 3) {
			if (check(x - 2, y)) {
				paper[x - 2][y] += 1;
			}
			if (check(x, y - 2)) {
				paper[x][y - 2] += 1;
			}
			if (check(x + 2, y)) {
				paper[x + 2][y] += 1;
			}
			if (check(x, y + 2)) {
				paper[x][y + 2] += 1;
			}

		}

	

	}
	int max = 0, blank = 0;
	for (int i = 0; i < 10; i++) {
		for (int j = 0; j < 10; j++) {
			if (paper[i][j] == 0) {
				blank += 1;
			}
			else {
				if (paper[i][j] > max) {
					max = paper[i][j];
				}
			}
		}
	}
	cout << blank << endl;
	cout << max << endl;

}