Go: package main

import (
	"bufio"
	"os"
	"strings"
	"strconv"
	"fmt"
)

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

func main() {
	scanner := bufio.NewScanner(os.Stdin)
	paper := make([][]int, 10)
	for i := range paper {
		paper[i] = make([]int, 10)
		for j := range paper[i] {
			paper[i][j] = 0
		}
	}
	// fmt.Println(paper)
	for scanner.Scan() {
		infos := strings.Split(scanner.Text(), ",")
		x, _ := strconv.Atoi(infos[0])
		y, _ := strconv.Atoi(infos[1])
		s, _ := strconv.Atoi(infos[2])
		// fmt.Println(x, y, s)
		switch s {
		case 1:
			paper[x][y]++
			if rangeCheck(x, y-1) {
				paper[x][y-1]++
			}
			if rangeCheck(x, y+1) {
				paper[x][y+1]++
			}
			if rangeCheck(x-1, y) {
				paper[x-1][y]++
			}
			if rangeCheck(x+1, y) {
				paper[x+1][y]++
			}
			continue
		case 2:
			paper[x][y]++
			if rangeCheck(x-1, y-1) {
				paper[x-1][y-1]++
			}
			if rangeCheck(x, y-1) {
				paper[x][y-1]++
			}
			if rangeCheck(x+1, y-1) {
				paper[x+1][y-1]++
			}
			if rangeCheck(x-1, y) {
				paper[x-1][y]++
			}
			if rangeCheck(x+1, y) {
				paper[x+1][y]++
			}
			if rangeCheck(x-1, y+1) {
				paper[x-1][y+1]++
			}
			if rangeCheck(x, y+1) {
				paper[x][y+1]++
			}
			if rangeCheck(x+1, y+1) {
				paper[x+1][y+1]++
			}
			continue
		case 3:
			paper[x][y]++
			if rangeCheck(x-1,y-1) {
				paper[x-1][y-1]++
			}
			if rangeCheck(x,y-1) {
				paper[x][y-1]++
			}
			if rangeCheck(x+1,y-1) {
				paper[x+1][y-1]++
			}
			if rangeCheck(x-1,y) {
				paper[x-1][y]++
			}
			if rangeCheck(x+1,y) {
				paper[x+1][y]++
			}
			if rangeCheck(x-1,y+1) {
				paper[x-1][y+1]++
			}
			if rangeCheck(x,y+1) {
				paper[x][y+1]++
			}
			if rangeCheck(x+1,y+1) {
				paper[x+1][y+1]++
			}
			if rangeCheck(x,y-2) {
				paper[x][y-2]++
			}
			if rangeCheck(x-2,y) {
				paper[x-2][y]++
			}
			if rangeCheck(x+2,y) {
				paper[x+2][y]++
			}
			if rangeCheck(x,y+2) {
				paper[x][y+2]++
			}
			continue
		}
	}
	count := 0
	max := -1
	for i := range paper {
		for j := range paper[i] {
			if paper[i][j] == 0 {
				count++
			}
			if max >= paper[i][j] {
				max = max
			} else {
				max = paper[i][j]
			}
		}
	}
	fmt.Printf("%d\n%d", count, max)
}

C++: #include<stdio.h>

int main(void){
  int xs[] = {-1,0,0,1},ys[] = {0,-1,1,0};
  int xm[] = {-1,-1,-1,0,0,1,1,1}, ym[] = {-1,0,1,-1,1,-1,0,1};
  int xl[] = {-2,-1,-1,-1,0,0,0,0,1,1,1,2};
  int yl[] = {0,-1,0,1,-2,-1,1,2,-1,0,1,0};

  int x,y,n;
  int max = 0, cnt = 0;

  int map[14][14] = {0};

  while(scanf("%d,%d,%d",&x,&y,&n) != EOF){
    x += 2;
    y += 2;
    switch(n){
    case 1:
      map[x][y]++;
      for(int i = 0; i < 4; i++){
	map[x + xs[i]][y + ys[i]]++;
      }
      break;

    case 2:
      map[x][y]++;
      for(int i = 0; i < 8; i++){
	map[x + xm[i]][y + ym[i]]++;
      }
      break;

    case 3:
      map[x][y]++;
      for(int i = 0; i < 12; i++){
	map[x + xl[i]][y + yl[i]]++;
      }
      break;
    }
  }

  for(int i = 2; i < 12; i++){
    for(int j = 2; j < 12; j++){
      if(map[i][j] == 0){
	cnt++;
      }
      if(map[i][j] > max){
	max = map[i][j];
      }
    }
  }
    
  printf("%d\n%d\n",cnt,max);

  return 0;
}

C++: #include <iostream>
#include <string>
using namespace std;
int main(){
int x;
int y;
int s;
int a[14][14];
char b;
int c;
int d;
c=0;
while(c<14){
d=0;
while(d<14){
a[c][d]=0;
d=d+1;}
c=c+1;}
while(cin>>x>>b>>y>>b>>s){
if(s==1){
a[x+2][y+2]=a[x+2][y+2]+1;
a[x+1][y+2]=a[x+1][y+2]+1;
a[x+3][y+2]=a[x+3][y+2]+1;
a[x+2][y+1]=a[x+2][y+1]+1;
a[x+2][y+3]=a[x+2][y+3]+1;}
if(s==2){
a[x+1][y+1]=a[x+1][y+1]+1;
a[x+1][y+2]=a[x+1][y+2]+1;
a[x+1][y+3]=a[x+1][y+3]+1;
a[x+2][y+1]=a[x+2][y+1]+1;
a[x+2][y+2]=a[x+2][y+2]+1;
a[x+2][y+3]=a[x+2][y+3]+1;
a[x+3][y+1]=a[x+3][y+1]+1;
a[x+3][y+2]=a[x+3][y+2]+1;
a[x+3][y+3]=a[x+3][y+3]+1;}
if(s==3){
a[x][y+2]=a[x][y+2]+1;
a[x+1][y+1]=a[x+1][y+2]+1;
a[x+1][y+2]=a[x+1][y+2]+1;
a[x+1][y+3]=a[x+1][y+3]+1;
a[x+2][y]=a[x+2][y]+1;
a[x+2][y+1]=a[x+2][y+1]+1;
a[x+2][y+2]=a[x+2][y+2]+1;
a[x+2][y+3]=a[x+2][y+3]+1;
a[x+2][y+4]=a[x+2][y+4]+1;
a[x+3][y+1]=a[x+3][y+1]+1;
a[x+3][y+2]=a[x+3][y+2]+1;
a[x+3][y+3]=a[x+3][y+3]+1;
a[x+4][y+2]=a[x+2][y+2]+1;}
}
int e;
int f;
e=a[2][2];
f=0;
c=2;
while(c<12){
d=2;
while(d<12){
if(e<a[c][d]){e=a[c][d];}
if(a[c][d]==0){f=f+1;}
d=d+1;}
c=c+1;}
cout <<f<<endl<<e<<endl;}

C++: #include<stdio.h>

int main(){
	int i,j,x,y,size,map[15][15]={0},noud=0,no=0;
	while(scanf("%d,%d,%d",&x,&y,&size)!=EOF){
		switch(size){
			case 3:
				map[x][y+2]++;
				map[x+2][y]++;
				map[x+2][y+4]++;
				map[x+4][y+2]++;
			case 2:
				map[x+1][y+1]++;
				map[x+1][y+3]++;
				map[x+3][y+1]++;
				map[x+3][y+3]++;
			case 1:
				map[x+1][y+2]++;
				map[x+2][y+1]++;
				map[x+2][y+2]++;
				map[x+3][y+2]++;
				map[x+2][y+3]++;
		}
	}
	for(i=0;i<10;i++){
		for(j=0;j<10;j++){
			if(map[i+2][j+2]==0)no++;
			if(map[i+2][j+2]>noud)noud=map[i+2][j+2];
		}
	}
	printf("%d\n%d\n",no,noud);
}

C++: #include <iostream>
#include <vector>
#include <algorithm>
#include <string>
#include <sstream>
#include <climits>
using namespace std;

#define Vint vector<int>
#define VVint vector<Vint>
#define Fsize() front().size()

int VVint_zero(VVint vv) {
	int num = 0;
	for (int i = 0; i < vv.size(); i++) {
		for (int j = 0; j < vv.Fsize(); j++) {
			if (vv[i][j] == 0) num++;
		}
	}
	return num;
}

int VVint_max(VVint vv) {
	int max = INT_MIN;
	for (int i = 0; i < vv.size(); i++) {
		for (int j = 0; j < vv.Fsize(); j++) {
			if (vv[i][j] > max) max = vv[i][j];
		}
	}
	return max;
}

int main() {
	int x, y, s;
	string str, str_x, str_y, str_s;
	VVint vec(10, Vint(10, 0));
	while (getline(cin, str)) {
		replace(str.begin(), str.end(), ',', ' ');
		istringstream iss(str);
		iss >> str_x >> str_y >> str_s;
		x = stoi(str_x);
		y = stoi(str_y);
		s = stoi(str_s);
		vec[y][x] += 1;
		if (s == 1 || s == 2 || s == 3) {
			if (y - 1 >= 0) vec[y - 1][x] += 1;
			if (y + 1 >= 0) vec[y + 1][x] += 1;
			if (x - 1 >= 0) vec[y][x - 1] += 1;
			if (x + 1 >= 0) vec[y][x + 1] += 1;
		}
		if (s == 2 || s == 3) {
			if (y - 1 >= 0 && x - 1 >= 0) vec[y - 1][x - 1] += 1;
			if (y - 1 >= 0 && x + 1 >= 0) vec[y - 1][x + 1] += 1;
			if (y + 1 >= 0 && x - 1 >= 0) vec[y + 1][x - 1] += 1;
			if (y + 1 >= 0 && x + 1 >= 0) vec[y + 1][x + 1] += 1;
		}
		if (s == 3) {
			if (y - 2 >= 0) vec[y - 2][x] += 1;
			if (y + 2 >= 0) vec[y + 2][x] += 1;
			if (x - 2 >= 0) vec[y][x - 2] += 1;
			if (x + 2 >= 0) vec[y][x + 2] += 1;
		}
	}
	cout << VVint_zero(vec) << endl;
	cout << VVint_max(vec) << endl;
	return 0;
}

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

int p[14][14];

int main()
{
  int x, y, s;

  while (scanf("%d,%d,%d", &x, &y, &s) != EOF){
    p[x + 2][y + 1] += 1;
    p[x + 1][y + 2] += 1;
    p[x + 2][y + 2] += 1;
    p[x + 3][y + 2] += 1;
    p[x + 2][y + 3] += 1;

    if (s >= 2){
      p[x + 1][y + 1] += 1;
      p[x + 3][y + 1] += 1;
      p[x + 1][y + 3] += 1;
      p[x + 3][y + 3] += 1;
    }

    if (s == 3){
      p[x][y + 2] += 1;
      p[x + 2][y] += 1;
      p[x + 4][y + 2] += 1;
      p[x + 2][y + 4] += 1;
    }
  }

  int cnt, max;

  cnt = max = 0;

  for (int i = 2; i < 12; i++){
    for (int j = 2; j < 12; j++){
      if (p[i][j] == 0){
        cnt++;
      }
      if (max < p[i][j]){
        max = p[i][j];
      }
    }
  }
  cout << cnt << endl << max << endl;
}