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<string>
#include<cstdio>
#include<algorithm>
#include<stack>
#include<queue>
#include<vector>
#include<cmath>
#include<utility>
#include<set>
#include<complex>
#define vi vector<int>
#define vvi vector<vector<int> >
#define ll long long int
#define vl vector<ll>
#define vvl vector<vector<ll>>
#define ld long double
#define INF 1e9
#define EPS 0.0000000001
#define rep(i,n) for(int i=0;i<n;i++)
#define CC puts("-------ok--------");
#define all(in) in.begin(), in.end()
#define bv vector<bool>
using namespace std;
typedef pair<int, int>PA;
using namespace std;
#define MAX 1e7
int sx[] = {0,0,-1,1};
int sy[] = {1,-1,0,0};
int my[] = {0,0,1,1,1,-1,-1,-1};
int mx[] = {1,-1,0,1,-1,0,1,-1};
int lx[] = {0,0,0,0,1,1,1,2,-1,-1,-1,-2};
int ly[] = {1,-1,2,-2,0,1,-1,0,0,-1,1,0};
int  main(){
    
    vvi v(12,vi(12,0));
    vi x(100,0); vi y(100,0); vi ink(100,0);
    int i =0; char c,d;
    while(cin >> x[i] >>c>>y[i] >>d >> ink[i]){
        v[y[i]][x[i]]+=1;
        if(ink[i] == 1){
            rep(j,4){
                int tx =x[i]+sx[j]; int ty = y[i]+sy[j];
                if(0<=tx && tx<10 && 0<=ty && ty<10)
                    v[ty][tx]+=1;
            }
        }else if(ink[i] == 2){
            rep(j,8){
                int tx =x[i]+mx[j]; int ty = y[i]+my[j];
                if(0<=tx && tx<10 && 0<=ty && ty<10)
                    v[ty][tx]+=1;
                }
        }else if(ink[i] == 3){
                rep(j,12){
                    int tx =x[i]+lx[j]; int ty = y[i]+ly[j];
                    if(0<=tx && tx<10 && 0<=ty && ty<10)
                        v[ty][tx]+=1;
                }
        }
        i++;
    }
        int ans1 = -INF; int ans2 = 0;
        rep(i,10) rep(j,10){
            ans1 = max(ans1,v[i][j]);
            if(v[i][j]  == 0)
                ans2++;
        }
    cout << ans2<< endl;
    cout << ans1<< endl;
        
    return 0;
}

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


using namespace std;

int paper[10][10];

bool range(int x, int y)
{
	return x >= 0 && y >= 0 && x < 10 && y < 10;
}

void dropMedium(int x, int y)
{
	for (int dy = -1; dy <= 1; ++dy)
	{
		for (int dx = -1; dx <= 1; ++dx)
		{
			int xx = x+dx;
			int yy = y+dy;
			if (range(xx, yy))
				++paper[yy][xx];
		}
	}
}
void dropSmall(int x, int y, int d = 1)
{
	int dx[] = { 0, 0, 1, 0, -1 };
	int dy[] = { 0, 1, 0, -1, 0 };
	for (int i = 0; i < 5; ++i)
	{
		int xx = x+d*dx[i];
		int yy = y+d*dy[i];
		if (range(xx, yy))
			++paper[yy][xx];
	}
}
void dropLarge(int x, int y)
{
	dropSmall(x, y, 2);
	dropMedium(x, y);
	--paper[y][x];
}


int main()
{
	int x, y, s;
	while (scanf("%d,%d,%d", &x, &y, &s) != EOF)
	{
		switch (s)
		{
			case 1: dropSmall(x, y); break;
			case 2: dropMedium(x, y); break;
			case 3: dropLarge(x, y); break;
		}
	}
	int empties = 0;
	int m = 0;
	for (int y = 0; y < 10; ++y)
	{
		for (int x = 0; x < 10; ++x)
		{
			if (paper[y][x] == 0)
				++empties;
			m = max(m, paper[y][x]);
		}
	}
	printf("%d\n%d\n", empties, m);

	return 0;
}

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

int main()
{
	int xy[10][10] = {'0'};
	int x,y,size;
	xy[0][0] = 0;
	
	while(scanf("%d,%d,%d", &x,&y,&size), x != EOF){
		
		xy[y-1][x]++;
		xy[y][x-1]++;
		xy[y][x]++;
		xy[y][x+1]++;
		xy[y+1][x]++;
		
		if(size >= 2){
			xy[y-1][x-1]++;
			xy[y-1][x+1]++;
			xy[y+1][x-1]++;
			xy[y+1][x+1]++;
		}
		if(size == 3){
			xy[y-2][x]++;
			xy[y][x-2]++;
			xy[y][x+2]++;
			xy[y+2][x]++;
		}
	}
	
	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<functional>
#include<algorithm>
#include<iostream>
#include<utility>
#include<string>
#include<vector>
#include<cmath>
#include<stack>
#include<queue>
#include<deque>
#include<map>
#define rep(i,n) for(int i=0;i<n;i++)
#define loop(i,x,n) for(int i=x;i<n;i++)
#define pf push_front
#define pb push_back
#define int long long
using namespace std;
const int INF=1000000007;
int dx[4]={1,0,-1,0};
int dy[4]={0,1,0,-1};
int ex[4]={1,-1,1,-1};
int ey[4]={1,1,-1,-1};
int fx[4]={2,0,-2,0};
int fy[4]={0,2,0,-2};

int mp[20][20]={};

signed main(){
  int x,y,s;
  char z;
  while(cin>>x>>z>>y>>z>>s){
    if(s==1){
      mp[y][x]+=1;
      rep(i,4){
        if(y+dy[i]>=0&&x+dx[i]>=0){
          mp[y+dy[i]][x+dx[i]]+=1;
        }
      }
    }
    else if(s==2){
      mp[y][x]+=1;
      rep(i,4){
        if(y+dy[i]>=0&&x+dx[i]>=0){
          mp[y+dy[i]][x+dx[i]]+=1;
        }
        if(y+ey[i]>=0&&x+ex[i]>=0){
          mp[y+ey[i]][x+ex[i]]+=1;
        }
      }
    }
    else if(s==3){
      mp[y][x]+=1;
      rep(i,4){
        if(y+dy[i]>=0&&x+dx[i]>=0){
          mp[y+dy[i]][x+dx[i]]+=1;
        }
        if(y+ey[i]>=0&&x+ex[i]>=0){
          mp[y+ey[i]][x+ex[i]]+=1;
        }
        if(y+fy[i]>=0&&x+fx[i]>=0){
          mp[y+fy[i]][x+fx[i]]+=1;
        }
      }
    }
  }
  int ans1=0,ans2=0;
  rep(i,10){
    rep(j,10){
      if(mp[i][j]==0)ans1++;
      if(ans2<mp[i][j])ans2=mp[i][j];
    }
  }
  cout<<ans1<<endl;
  cout<<ans2<<endl;
  return 0;
}

C++: #include <iostream>
using namespace std;
int depth[11][11];
int dx[] = {0,  0,  0,  1, -1,  1,  1, -1, -1,  0,  0,  2, -2};
int dy[] = {0,  1, -1,  0,  0, -1,  1,  1, -1,  2, -2,  0,  0};
int ans;
int total;
void draw(int x, int y, int size){
	for(int i = 0; i < size*4+1; i++){
		int nx = x + dx[i];
		int ny = y + dy[i];
		if( nx < 0 || nx >= 10 || ny < 0 || ny >= 10) continue;
		depth[ny][nx]++;
		ans = max(ans, depth[ny][nx]);
		if(depth[ny][nx] == 1)total--;
	}
}
int main(){
	int x, y , size;
	char c;
	total = 10*10;
	while(cin >> x >> c >> y >> c >> size){
		draw(x,y,size);
	}
	cout << total << endl;
	cout << ans << endl;
	return 0;
}