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>
using namespace std;
int main()
{
    int ma[10][10];
    int x,y,d;
    char c;
    memset(ma,0,sizeof(ma));
    //while(cin>>x>>c>>y>>c>>d){
    for(int i=0;i<6;i++){
        
        cin>>x>>c>>y>>c>>d;
        
        ma[y][x]++;
        if(d==1){
            if(x>0){
                ma[y][x-1]++;
            }
            if(x<9){
                ma[y][x+1]++;
            }
            if(y>0){
                ma[y-1][x]++;
            }
            if(y<9){
                ma[y+1][x]++;
            }
        }
        else if(d==2){
            if(x>0){
                ma[y][x-1]++;
            }
            if(x<9){
                ma[y][x+1]++;
            }
            if(y>0){
                ma[y-1][x]++;
            }
            if(y<9){
                ma[y+1][x]++;
            }
            if(x>0&&y<9){
                ma[y+1][x-1]++;
            }
            if(x<9&&y>0){
                ma[y-1][x+1]++;
            }
            if(x>0&&y>0){
                ma[y-1][x-1]++;
            }
            if(x<9&&y<9){
                ma[y+1][x+1]++;
            }
        }
        else{
            if(x>0){
                ma[y][x-1]++;
            }
            if(x<9){
                ma[y][x+1]++;
            }
            if(y>0){
                ma[y-1][x]++;
            }
            if(y<9){
                ma[y+1][x]++;
            }
            if(x>0&&y<9){
                ma[y+1][x-1]++;
            }
            if(x<9&&y>0){
                ma[y-1][x+1]++;
            }
            if(x>0&&y>0){
                ma[y-1][x-1]++;
            }
            if(x<9&&y<9){
                ma[y+1][x+1]++;
            }
            if(x>1){
                ma[y][x-2]++;
            }
            if(x<8){
                ma[y][x+2]++;
            }
            if(y>1){
                ma[y-2][x]++;
            }
            if(y<8){
                ma[y+2][x]++;
            }
        }
    }
    int em=0,m=0;
    for(int i=0;i<10;i++){
        for(int j=0;j<10;j++){
            if(ma[i][j]==0)em++;
            m=max(m,ma[i][j]);
        }
    }
    cout<<em<<endl<<m<<endl;
    return 0;
}

C++: #define _GLIBCXX_DEBUG
#define rep(i, n) for (int i = 0; i < (int)(n); i++)
#define ALL(v) v.begin(), v.end()
typedef long long ll;

template<class T>bool chmax(T &a, const T &b) { if (a<b) { a=b; return 1; } return 0; }
template<class T>bool chmin(T &a, const T &b) { if (b<a) { a=b; return 1; } return 0; }

#include <bits/stdc++.h>
using namespace std;
  

int main() {
  int vec[14][14];
  rep(i,14){
    rep(j,14) vec[i][j]=0;
  }
  
  int a,b,c;
  char x,y;
  while(cin>>a>>x>>b>>y>>c){
    
    vec[a+2][b+2]++;
    vec[a+1][b+2]++;
    vec[a+3][b+2]++;
    vec[a+2][b+1]++;
    vec[a+2][b+3]++;
    if(c>1){
      vec[a+1][b+1]++;
      vec[a+1][b+3]++;
      vec[a+3][b+1]++;
      vec[a+3][b+3]++;
    }
    if(c>2){
      vec[a][b+2]++;
      vec[a+4][b+2]++;
      vec[a+2][b]++;
      vec[a+2][b+4]++;
    }
  }
    
  int ma=0,cnt=0;
    
  for(int i=2;i<=11;i++){
    for(int j=2;j<=11;j++){
      if(vec[i][j]==0) cnt++;
      chmax(ma,vec[i][j]);
    }
  }
    
  cout<<cnt<<endl;
  cout<<ma<<endl;
      
  return 0;
}

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

int main(){
	vector<vector<int> > field(14, vector<int>(14, 0));
	int x,y,s;
	while(scanf("%d,%d,%d", &x, &y, &s)!=EOF){
		x+=2; y+=2;
		for(int i=-2; i<=2; i++){
			for(int j=-2; j<=2; j++){
				if(s==1 && abs(i)+abs(j)<=1){
					field[x+i][y+j]++;
				}
				if(s==2 && abs(i)<=1 && abs(j)<=1){
					field[x+i][y+j]++;
				}
				if(s==3 && abs(i)+abs(j)<=2){
					field[x+i][y+j]++;
				}
			}
		}
	}
	
	int white = 0;
	int deep = 0;
	for(int i=2; i<=11; i++){
		for(int j=2; j<=11; j++){
			deep = max(deep, field[i][j]);
			if(field[i][j] == 0 ) white++;
		}
	}
	cout << white << endl << deep << endl; 
    return 0;
}

C++: #include <cstdio>

int ds[][2]={{0,0},{1,0},{0,1},{-1,0},{0,-1},{1,1},{1,-1},{-1,1},{-1,-1},{2,0},{0,2},{-2,0},{0,-2}};
int map[10][10],kosa,rest=100;

int max(int a,int b){return a>b?a:b;}

int drop(int x,int y){
  if(x>=0 && x<10 && y>=0 && y<10){
    if(map[x][y]++==0) rest--;
    kosa=max(map[x][y],kosa);
  }
}

int main(){
  int x,y,size;
  while(~scanf("%d,%d,%d",&x,&y,&size))
    for(int i=0; i<=4*size; i++)
      drop(x+ds[i][0],y+ds[i][1]);

  printf("%d\n%d\n",rest,kosa);
}

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

int main() {
	int x, y, size;
	int sol[10][10];
	char c;
	for(int i = 0; i < 10; i++) {
		for(int j = 0; j < 10; j++) {
			sol[i][j] = 0;
		}
	}
	while(cin >> x >> c >> y >> c >> size) {
		if(size == 1) {
			sol[x][y]++;
			if(x - 1 >= 0) sol[x-1][y]++;
			if(y - 1 >= 0) sol[x][y-1]++;
			if(x + 1 < 10) sol[x+1][y]++;
			if(y + 1 < 10) sol[x][y+1]++;
		}
		else if(size == 2) {
			sol[x][y]++;
			if(x - 1 >= 0) sol[x-1][y]++;
			if(y - 1 >= 0) sol[x][y-1]++;
			if(x + 1 >= 0) sol[x+1][y]++;
			if(y + 1 >= 0) sol[x][y+1]++;
			if(x-1 >= 0 && y-1 >= 0) sol[x-1][y-1]++;
			if(x+1 < 10 && y-1 >= 0) sol[x+1][y-1]++;
			if(x-1 >= 0 && y+1 < 10) sol[x-1][y+1]++;
			if(x+1 < 10 && y+1 < 10) sol[x+1][y+1]++;
		}
		else {
			sol[x][y]++;
			if(x - 1 >= 0) sol[x-1][y]++;
			if(y - 1 >= 0) sol[x][y-1]++;
			if(x + 1 >= 0) sol[x+1][y]++;
			if(y + 1 >= 0) sol[x][y+1]++;
			if(x-1 >= 0 && y-1 >= 0) sol[x-1][y-1]++;
			if(x+1 < 10 && y-1 >= 0) sol[x+1][y-1]++;
			if(x-1 >= 0 && y+1 < 10) sol[x-1][y+1]++;
			if(x+1 < 10 && y+1 < 10) sol[x+1][y+1]++;
			if(y - 2 >= 0) sol[x][y-2]++;
			if(y + 2 < 10) sol[x][y+2]++;
			if(x - 2 >= 0) sol[x-2][y]++;
			if(x + 2 < 10) sol[x+2][y]++; 
		}
		/*
		for(int i = 0; i < 10; i++) {
			for(int j = 0; j < 10; j++) {
				cout << sol[i][j] << " " ;
			}
			cout << endl;
		}
		*/
	}
	int count = 0;
	int max = 0;
	for(int i = 0; i < 10; i++) {
		for(int j = 0; j < 10; j++) {
			if(sol[i][j] == 0) count++;
			if(sol[i][j] > max) max = sol[i][j];
		}
	}
	cout << count << endl;
	cout << max << endl;
	return 0;
}