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>
using namespace std;
int main(){
int vx[]={ 0, 1,-1, 0, 0,-1,-1, 1, 1, 2,-2, 0, 0};
int vy[]={ 0, 0, 0, 1,-1,-1, 1,-1, 1, 0, 0, 2,-2};
int x,y,size;
int map[10][10];
for(int i=0;i<10;i++){
for(int j=0;j<10;j++){
map[i][j]=0;
}
}
int nm_ans=0,max_ans=0;
while(scanf("%d,%d,%d",&x,&y,&size)!=EOF){
switch(size){
case 1:
for(int i=0;i<5;i++){
if((min(x+vx[i],y+vy[i])>=0)&&max(x+vx[i],y+vy[i])<10){
map[x+vx[i]][y+vy[i]]++;
}
}
break;
case 2:
for(int i=0;i<9;i++){
if((min(x+vx[i],y+vy[i])>=0)&&max(x+vx[i],y+vy[i])<10){
map[x+vx[i]][y+vy[i]]++;
}
}
break;
case 3:
for(int i=0;i<13;i++){
if((min(x+vx[i],y+vy[i])>=0)&&max(x+vx[i],y+vy[i])<10){
map[x+vx[i]][y+vy[i]]++;
}
}
break;
}
}
for(int i=0;i<10;i++){
for(int j=0;j<10;j++){
if(map[i][j]>max_ans){
max_ans=map[i][j];
}
if(map[i][j]==0){
nm_ans++;
}
}
}
cout<<nm_ans<<endl;
cout<<max_ans<<endl;
return 0;
}

C++: #include<iostream>

using namespace std;

int main(){

  int data[10][10], x, y, size, sum = 0, max = 0;
  char trash[2];


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


  while(cin >> x >> trash[0] >> y >> trash[1] >> size){

    if(size == 1){

      data[x][y]++;
      data[x][y-1]++;
      data[x-1][y]++;
      data[x+1][y]++;
      data[x][y+1]++;

    }else if(size == 2){

      data[x][y]++;
      data[x][y-1]++;
      data[x-1][y]++;
      data[x+1][y]++;
      data[x][y+1]++;
      data[x-1][y-1]++;
      data[x+1][y-1]++;
      data[x-1][y+1]++;
      data[x+1][y+1]++;

    }else{

      data[x][y]++;
      data[x][y-1]++;
      data[x-1][y]++;
      data[x+1][y]++;
      data[x][y+1]++;
      data[x-1][y-1]++;
      data[x+1][y-1]++;
      data[x-1][y+1]++;
      data[x+1][y+1]++;
      data[x-2][y]++;
      data[x+2][y]++;
      data[x][y+2]++;
      data[x][y-2]++;

      
 
    }
  }


  for(int i = 0; i < 10; i++){
    for(int j = 0; j < 10; j++){
      if(data[i][j] == 0){
	sum++;
      }
      if(data[i][j] > max){
	max = data[i][j];
      }
    }
  }

  cout << sum << endl << max<<endl;

  return 0;

}

C++: #include<iostream>
#include<stdio.h>
using namespace std;
int main(){
  int dec[10][10];
  int x,y,size,num,max;
  char a;
  num = 0;
  for(int i=0;i<10;i++){
    for(int j=0;j<10;j++){
       dec[i][j]=0;
    }
  }
                 
  while(cin >> y >> a>> x>> a>> size){
    if(size == 1){
      if(x+1 < 10 && x+1 >= 0 && y>=0 && y<10) dec[x+1][y] += 1;
      if(x-1 >=0 && x-1 < 10 && y>=0 && y<10) dec[x-1][y] += 1;
      if(x >= 0 && x < 10 && y+1<10 && y+1 >= 0) dec[x][y+1] += 1;
     if(x >=0 && x< 10 && y-1 <10 && y-1 >=0) dec[x][y-1] += 1;
        dec[x][y] += 1;
        } else if(size == 2){
      for(int i=-1;i<=1;i++){
    for(int j=-1;j<=1;j++){
      if(x+i >=0&& x+i<10 && y+j>=0&& y+j<10) dec[x+i][y+j] +=1;
    }
      }
    }else if(size==3){
      for(int i=-1;i<=1;i++){
    for(int j=-1;j<=1;j++){
      if(x+i >=0&& x+i<10 && y+j>=0&& y+j<10)  dec[x+i][y+j] +=1;
    }
      }
      if(x+2<10 && x+2 >=0 && y>=0 && y<10  )dec[x+2][y] +=1;
      if(x-2>=0 &&x-2 <10 && y>=0 && y<10  )dec[x-2][y] +=1;
      if(x<10 && x >=0 && y+2>=0 && y+2<10  )dec[x][y+2] +=1;
      if(x>=0 && x<10 && y-2>=0 && y-2<10  )dec[x][y-2] +=1;
    }
  }
  max = dec[0][0];
  for(int i=0;i<10;i++){
    for(int j=0;j<10;j++){ 
      if(dec[i][j]==0)
    num +=1; 
      if(max < dec[i][j])
    max=dec[i][j];
    }
  }
  cout << num << endl << max<<endl;
}

C++: #include <iostream>
#include <cmath>
#include <vector>
#include <cstdio>
#include <algorithm>
using namespace std;
int main ()
{
	int m[18][18] = {};
	int x, y, s;
	int dx1[4] = {0, 1, 0, -1}, dy1[4] = {1, 0, -1, 0};
	int dx2[8] = {0, 1, 1, 1, 0, -1, -1, -1}, dy2[8] = {1, 1, 0, -1, -1, -1, 0, 1};
	int dx3[12] = {0, -1, 0, 1, -2, -1, 1, 2, -1, 0, 1, 0}, dy3[12] = {2, 1, 1, 1, 0, 0, 0, 0, -1, -1, -1, -2};
	while (scanf("%d,%d,%d", &x, &y, &s) != EOF)
	{
		x += 3;
		y += 3;
		m[x][y]++;
		switch (s)
		{
		case 1:
			for (int i = 0; i < 4; i++)m[x + dx1[i]][y + dy1[i]]++;
			break;
		case 2:
			for (int i = 0; i < 8; i++)m[x + dx2[i]][y + dy2[i]]++;
			break;
		case 3:
			for (int i = 0; i < 12; i++)m[x + dx3[i]][y + dy3[i]]++;
			break;
		}
	}
	int ans1 = 0, ans2 = 0;
	for (int x = 3; x <13; x++)
	{
		for (int y = 3; y < 13; y++)
		{
			if (m[x][y] == 0)ans1++;
			ans2 = max(ans2, m[x][y]);
		}
	}
	cout << ans1 << endl << ans2 << endl;
	return 0;
}

C++: #include<iostream>
#include<stdio.h>
#include<math.h>
#include<vector>
using namespace std;
int main() {
	int i,j,k,l,m,n,o,x,y,z;
	int max = 0;
	int count = 0;
	vector< vector<int> > s;
	s.resize(10);
	for (i = 0; i < 14; i++) {
		s[i].resize(14);
	}
	for (j = 0; j < 14; j++) {
		for (k = 0; k < 14; k++) {
			s[j][k] = 0;
		}
	}
	while (scanf("%d,%d,%d", &x, &y, &z)) {
		if (z == 1) {
			s[x + 2][y + 2] += 1;
			s[x + 1][y + 2] += 1;
			s[x + 3][y + 2] += 1;
			s[x + 2][y + 1] += 1;
			s[x + 2][y + 3] += 1;
		}
		else if (z == 2) {
			for (l = x + 1; l <= x + 3; l++) {
				for (m = y + 1; m <= y + 3; m++) {
					s[l][m] += 1;
				}
			}
		}
		else if (z == 3) {
			for (l = x + 1; l <= x + 3; l++) {
				for (m = y + 1; m <= y + 3; m++) {
					s[l][m] += 1;
					s[x][y + 2] += 1;
					s[x + 4][y + 2] += 1;
					s[x + 2][y] += 1;
					s[x + 2][y + 4] += 1;
				}
			}
		}
	}
	for (n = 2; n < 12; n++) {
		for (o = 2; o < 12; o++) {
			if (max < s[n][o]) {
				max = s[n][o];
			}
			if (s[n][o] == 0) {
				count += 1;
			}
		}
	}
	cout << count << endl;
	cout << max << endl;
	return 0;
}

C++: #include<iostream>
using namespace std;
int main(){
	int a[10][10]={},x,y,size,dumy,max=0,ans=0;
	int mx[12]={0,-1,1,0,-1,1,-1,1,0,-2,2,0},my[12]={-1,0,0,1,-1,-1,1,1,-2,0,0,2};
	while(cin>>x>>y>>size!=EOF){
		dumy=4*size;
		for(int i=0;i<dumy;i++){
			if(x+mx[i]>=0&&y+my[i]>=0)
			a[x+mx[i]][y+my[i]]++;
		}
	}
	for(int i=0;i<10;i++){
		for(int j=0;j<10;j++){
			if(a[i][j]==0){
				ans++;
			}else{
				if(max<=a[i][j])
				max=a[i][j];
			}
		}
	}
	cout<<ans<<endl<<max<<endl;
return 0;
}