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;
int pos[10][10];
/*void p(){
	for(int i=0;i<10;++i){
		for(int j=0;j<10;++j){
			cout<<pos[i][j]<<" ";
		}
		cout<<endl;
	}
	cout<<endl;
}*/
main(){
	int tmp[3],ink2[3]={1,1,2};
	int ink[3][5][5]={
		{{0,1,0,0,0},{1,1,1,0,0},{0,1,0,0,0},{0,0,0,0,0},{0,0,0,0,0}},
		{{1,1,1,0,0},{1,1,1,0,0},{1,1,1,0,0},{0,0,0,0,0},{0,0,0,0,0}},
		{{0,0,1,0,0},{0,1,1,1,0},{1,1,1,1,1},{0,1,1,1,0},{0,0,1,0,0}}
	};
	for(int i=0;i<10;++i)
		for(int j=0;j<10;++j)
			pos[i][j]=0;
	for(int loop=0;loop<6;++loop){
		scanf("%d,%d,%d",&tmp[0],&tmp[1],&tmp[2]);
		for(int i=0;i<5;++i){
			for(int j=0;j<5;++j){
				int t[2]={tmp[0]-ink2[tmp[2]-1]+i,tmp[1]-ink2[tmp[2]-1]+j};
				if(t[0]>=0 && t[0]<=9 && t[1]>=0 && t[1]<=9){
					pos[t[0]][t[1]]+=ink[tmp[2]-1][i][j];
				}
			}
		}
	}
	int ans[2]={0,0};
	for(int i=0;i<10;++i){
		for(int j=0;j<10;++j){
			if(pos[i][j]==0)ans[0]++;
			ans[1]=max(pos[i][j],ans[1]);
		}
	}
	cout<<ans[0]<<" "<<ans[1]<<endl;
}

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

int main(){
	int x,y,board[12][12],c=0,k=0;
	for(int i=0;i<10;i++){
		for(int j=0;j<10;j++){
			board[i][j]=0;
		}
	}	
	char input[5];
	while( scanf("%s",&input)!=EOF){
		x=input[0]-'0';
		y=input[2]-'0';
		if(input[4]=='1'){
			board[x][y]++;
			board[x+1][y]++;
			board[x-1][y]++;
			board[x][y+1]++;
			board[x][y-1]++;
		}
		if(input[4]=='2'){
			board[x][y]++;
			board[x+1][y]++;
			board[x-1][y]++;
			board[x][y+1]++;
			board[x][y-1]++;
			board[x+1][y+1]++;
			board[x-1][y-1]++;
			board[x-1][y+1]++;
			board[x+1][y-1]++;
		}
		if(input[4]=='3'){
			board[x][y]++;
			board[x+1][y]++;
			board[x-1][y]++;
			board[x][y+1]++;
			board[x][y-1]++;
			board[x+1][y+1]++;
			board[x-1][y-1]++;
			board[x-1][y+1]++;
			board[x+1][y-1]++;
			board[x+2][y]++;
			board[x-2][y]++;
			board[x][y+2]++;
			board[x][y-2]++;
		}
	}
	for(int i=0;i<10;i++){
		for(int j=0;j<10;j++){
			if(board[i][j]==0){
				c++;
			}
			if(board[i][j]>k){
				k=board[i][j];
			}
		}
	}
	printf("%d\n%d\n",c,k);
	
			
	return 0;
}

C++: #include<iostream>
#include<vector>
#include <algorithm>
#include<stdio.h>
int main(){
	std::vector<std::vector<int>> vec(10,std::vector<int>(10,0));
	while(1){
		int x,y,size;
		scanf("%d,%d,%d",&x,&y,&size);
		//std::cin>>x>>y>>size;
		if(scanf.eof())break;
		//if(x==0&&y==0&&size==0)break;
		vec[y][x]++;
		vec[y-1][x]++;
		vec[y+1][x]++;
		vec[y][x-1]++;
		vec[y][x+1]++;
		if(size>=2){
			vec[y-1][x-1]++;
			vec[y-1][x+1]++;
			vec[y+1][x-1]++;
			vec[y+1][x+1]++;
		}
		if(size==3){
			vec[y-2][x]++;
			vec[y+2][x]++;
			vec[y][x-2]++;
			vec[y][x+2]++;
		}
	}
	std::vector<int> vec2(100);
	for(int i=0;i<10;i++){
		for(int j=0;j<10;j++)vec2[i*10+j]=vec[i][j];
	}
	int no=0;
	for(int i=0;i<100;i++){
		if(vec2[i]==0)no++;
	}
	std::cout<<no<<std::endl;
	sort(vec2.begin(),vec2.end(),std::greater<int>());
	std::cout<<vec2[0]<<std::endl;
	return 0;
}

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

int ary[10][10];
int dx[20]={0,1,0,-1,0,1,-1,-1,1,2,0,-2,0};
int dy[20]={0,0,1,0,-1,1,1,-1,-1,0,2,0,-2};
int main(){
	int x,y,s;

	while(scanf("%d,%d,%d",&x,&y,&s)!=EOF){
		for(int i=0;i<=s*4;i++){
			if(0<=x+dx[i]&&x+dx[i]<10&&0<=y+dy[i]&&y+dy[i]<10){
				ary[x+dx[i]][y+dy[i]]++;
			}
		}
	}
	int cnt=0,res=0;
	for(int i=0;i<10;i++){
		for(int j=0;j<10;j++){
			if(ary[i][j]==0) cnt++;
			res=max(res,ary[i][j]);
		}
	}
	cout<<cnt<<endl<<res<<endl;
	return 0;
}

C++: #include<iostream>
#include<string>
#include<algorithm>
#include<map>
#include<set>
#include<utility>
#include<vector>
#include<cmath>
#include<cstring>
#include<cstdio>
#define loop(i,a,b) for(int i=a;i<b;i++) 
#define rep(i,a) loop(i,0,a)
#define rp(a) while(a--)
#define pb push_back
#define mp make_pair
#define all(in) in.begin(),in.end()
const double PI=acos(-1);
const double EPS=1e-10;
using namespace std;
typedef long long ll;
typedef vector<int> vi;
int main(){
	int in[14][14]={0};
	char d;
	int a,b,c;
	while(cin>>b>>d>>a>>d>>c){
		a+=2;b+=2;
		if(c==2)
			loop(i,-1,2)loop(j,-1,2)in[a+i][b+j]++;
		else if(c==1){
			loop(i,-1,2)loop(j,-1,2)if(i*j==0)in[a+i][b+j]++;
		}else{
			loop(i,-2,3)loop(j,-2,3)if(i*j==0||(abs(i)!=2&&abs(j)!=2))in[a+i][b+j]++;
		}
	}
	int co=0,ma=0;
	loop(i,2,12)loop(j,2,12){
		if(!in[i][j])co++;
		ma=max(ma,in[i][j]);
	}
	cout<<co<<endl;
	cout<<ma<<endl;
}

C++: #include<iostream>
#include<cstdio>
using namespace std;
int main(){
	int field[30][30];
	for(int i=0; i<30; i++){
		for(int l=0; l<30; l++){
			field[i][l] = 0;
		}
	}
	for(;;){
		int x,y,size;
		if(scanf("%d,%d,%d",&x,&y,&size) == EOF){break;}
		field[x+10][y+10]++;
		field[x+10][y+9]++;
		field[x+9][y+10]++;
		field[x+10][y+11]++;
		field[x+11][y+10]++;
		if(size>1){
			field[x+9][y+9]++;
			field[x+9][y+11]++;
			field[x+11][y+9]++;
			field[x+11][y+11]++;
		}
		if(size>2){
			field[x+10][y+8]++;
			field[x+10][y+12]++;
			field[x+12][y+10]++;
			field[x+8][y+10]++;
		}
	}
	int max = 0, white = 0;
	for(int i=10; i<20; i++){
		for(int l=10; l<20; l++){
			if(field[i][l] == 0){white++;}
			if(max<field[i][l]){max = field[i][l];}
		}
	}
	cout <<white<<endl<<max<<endl;
}

C++: #include<stdio.h>
 
int table[14][14];
 
int main(){
    int a,b,c;
    while(~scanf("%d,%d,%d",&a,&b,&c)){
        a+=2;
        b+=2;
        switch(c){
            case 3:
                table[a-2][b]++;
                table[a+2][b]++;
                table[a][b-2]++;
                table[a][b+2]++;
            case 2:
                table[a+1][b+1]++;
                table[a-1][b-1]++;
                table[a+1][b-1]++;
                table[a-1][b+1]++;
            case 1:
                table[a][b+1]++;
                table[a][b-1]++;
                table[a-1][b]++;
                table[a+1][b]++;
                table[a][b]++;
        }
    }
    int max=0;
    int ans=0;
    for(int i=2;i<12;i++){
        for(int j=2;j<12;j++){
            if(table[i][j]>0)ans++;
            if(table[i][j]>max)max=table[i][j];
        }
    }
    printf("%d\n%d\n",100-ans,max);
}