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 <algorithm>
#include <cstdio>

using namespace std;

#define XAXIS 10
#define YAXIS 10

int main(){
	int paper[XAXIS][YAXIS];
	int x,y,s;
	int white = 0, most=0;

	for(int i=0; i<XAXIS; i++)
	for(int j=0; j<YAXIS; j++)
		paper[i][j] = 0;

	while(scanf("%d,%d,%d", &x, &y, &s) != EOF){
		switch(s){
			case 3:
				if(x+2 <  XAXIS) paper[x+2][y] += 1;
				if(y+2 <  YAXIS) paper[x][y+2] += 1;
				if(x-2 >= 0)     paper[x-2][y] += 1;
				if(y-2 >= 0)     paper[x][y-2] += 1;

			case 2:
				if(x+1 <  XAXIS && y+1 < YAXIS )  paper[x+1][y+1] += 1;
				if(x+1 <  XAXIS && y-1 >= 0)       paper[x+1][y-1] += 1;
				if(x-1 >= 0     && y+1 < YAXIS )  paper[x-1][y+1] += 1;
				if(x-1 >= 0     && y-1 >= 0)       paper[x-1][y-1] += 1;

			case 1:
				if(x+1 <  XAXIS) paper[x+1][y] += 1;
				if(y+1 <  YAXIS) paper[x][y+1] += 1;
				if(x-1 >= 0)     paper[x-1][y] += 1;
				if(y-1 >= 0)     paper[x][y-1] += 1;
				paper[x][y] += 1;
				break;
		}
	}

	for(int i=0; i<XAXIS; i++)
	for(int j=0; j<YAXIS; j++){
		if(paper[i][j] == 0 )  white++;
		most = max(most,paper[i][j]);
	}

	cout<<white<<endl<<most<<endl;
	return 0;
}

C++: #include<stdio.h>

int main()
{
	int m[10][10]={0},
		incX[3][14]={
			{0,-1,0,1,0,3},
			{-1,0,1,-1,0,1,-1,0,1,3},
			{0,-1,0,1,-2,-1,0,1,2,-1,0,1,0,3}},
		incY[3][14]={
			{-1,0,0,0,1,3},
			{-1,-1,-1,0,0,0,1,1,1,3},
			{-2,-1,-1,-1,0,0,0,0,0,1,1,1,2,3}},
			x,y,s,b=0,max=0;
	while(scanf("%d,%d,%d",&x,&y,&s)!=EOF)
	{
		for(int i=0;incX[s-1][i]!=3||incY[s-1][i]!=3;i++)
		{
			int X=x+incX[s-1][i],Y=y+incY[s-1][i];
			if(X>=0 && X<10 && Y>=0 && Y<10)
				m[Y][X]+=1;
		}
	}
	for(int i=0;i<10;i++)
		for(int j=0;j<10;j++)
		{
			if(m[i][j]==0)
				b++;
			else if(max<m[i][j])
				max=m[i][j];
		}
	printf("%d\n%d\n",b,max);
	return 0;
}

C++: #include<iostream>
#include<cstdio>
using namespace std;
#define loop(i,a,b) for(int i = a ; i < b ; i++)
#define rep(i,a) for(int i = 0 ; i < a ; i++) 

int maze[10][10];
int smallx[5] = { 1,-1, 0, 0, 0};
int smally[5] = { 0, 0, 0, 1,-1};
int midx[4] = { 1, 1,-1,-1};
int midy[4] = { 1,-1, 1,-1};
int largex[4] = { 2,-2, 0, 0};
int largey[4] = { 0, 0, 2,-2};

bool inmaze(int x,int y){
  return (0<=x && x<10) && (0<=y && y<10);
	     
}
void Fsmall(int x,int y){
  rep(i,5)
    if(inmaze(x+smallx[i],y+smally[i]))
       maze[x+smallx[i]][y+smally[i]]++;
       
}
void Fmid(int x,int y){
  rep(i,4)
    if(inmaze(x+midx[i],y+midy[i]))
       maze[x+midx[i]][y+midy[i]]++;
}
void Flarge(int x,int y){
  rep(i,4)
    if(inmaze(x+largex[i],y+largey[i]))
    maze[x+largex[i]][y+largey[i]]++;
}
int main(void){
  int x,y,size;
  rep(i,10)rep(j,10)maze[i][j] = 0;
  while(scanf("%d,%d,%d",&x,&y,&size)!=EOF)
    switch(size){
    case 3:
      Flarge(x,y);
    case 2:
      Fmid(x,y);
    case 1:
      Fsmall(x,y);
    }
    
  int no = 0,ma = -1;
  rep(i,10)rep(j,10){
    if(maze[i][j] == 0)no ++;
    ma = max(ma,maze[i][j]);
  }
  cout<<no<<endl<<ma<<endl;
  
}

C++: #include<stdio.h>

int main(void)
{
	int i,j,k,paper[10][10]={0},x,y,n,c=0,max=0;
	
	for(k=0;k<6;k++){
		scanf("%d,%d,%d",&x,&y,&n);
		if(n==1){
			if(y-1>=0)paper[y-1][x]++;
			if(y+1<10)paper[y+1][x]++;
			if(x-1>=0)paper[y][x-1]++;
			if(x+1<10)paper[y][x+1]++;
			if(y>=0 && y<10 && x>=0 && x<10)paper[y][x]++;
		}
		if(n==2){
			if(y-1>=0)paper[y-1][x]++;
			if(y+1<10)paper[y+1][x]++;
			if(x-1>=0)paper[y][x-1]++;
			if(x+1<10)paper[y][x+1]++;
			if(y-1>=0 && x-1>=0)paper[y-1][x-1]++;
			if(y-1>=0 && x+1<10)paper[y-1][x+1]++;
			if(y+1<10 && x-1>=0)paper[y+1][x-1]++;
			if(y+1<10 && x+1<10)paper[y+1][x+1]++;
			if(y>=0 && y<10 && x>=0 && x<10)paper[y][x]++;
		}
		if(n==3){
			if(y-1>=0)paper[y-1][x]++;
			if(y+1<10)paper[y+1][x]++;
			if(x-1>=0)paper[y][x-1]++;
			if(x+1<10)paper[y][x+1]++;
			if(y-1>=0 && x-1>=0)paper[y-1][x-1]++;
			if(y-1>=0 && x+1<10)paper[y-1][x+1]++;
			if(y+1<10 && x-1>=0)paper[y+1][x-1]++;
			if(y+1<10 && x+1<10)paper[y+1][x+1]++;
			
			if(y-2>=0)paper[y-2][x]++;
			if(y+2<10)paper[y+2][x]++;
			if(x+2<10)paper[y][x+2]++;
			if(x-2>=0)paper[y][x-2]++;
			if(y>=0 && y<10 && x>=0 && x<10)paper[y][x]++;
		}
	}
	for(i=0;i<10;i++){
		for(j=0;j<10;j++){
			printf("%d ",paper[i][j]);
		}
		puts("");
	}
	printf("%d\n%d\n",c,max);
	return 0;
}

C++: #include<stdio.h>

static int map[11][11];

void small(int x,int y){
	map[y][x]+=1;
	map[y][x+1]+=1;
	map[y][x-1]+=1;
	map[y+1][x]+=1;
	map[y-1][x]+=1;
}

void midium(int x,int y){
	small(x,y);
	map[y+1][x+1]+=1;
	map[y-1][x-1]+=1;
	map[y-1][x+1]+=1;
	map[y+1][x-1]+=1;
}

void big(int x,int y){
	medium(x,y);
	map[y][x+2]+=1;
	map[y][x-2]+=1;
	map[y+2][x]+=1;
	map[y-2][x]+=1;
}


int main(){
	int x[1000],y[1000],select[1000];
	int i,j;
	int space=0,max=0;
	
	for(i=0;i<11;i++){
		for(j=0;j<11;j++)map[i][j]=0;
	}
	
	i=0;
	while(scanf("%d,%d,%d",&x[i],&y[i],&select[i])!=EOF){
		switch(select[i]){
		case 1:
			small(x[i]+1,y[i]+1);
			break;
		case 2:
			medium(x[i]+1,y[i]+1);
			break;
		case 3:
			big(x[i]+1,y[i]+1);
			break;
		}
		i++;
	}
	
	for(i=1;i<11;i++){
		for(j=1;j<11;j++){
			if(map[i][j]==0)space++;
			if(max<map[i][j])max=map[i][j];
		}
	}
	
	printf("%d\n%d\n",space,max);
	
	return 0;
}

C++: #include<iostream>
using namespace std;
int main(){
  int k[10][10]={0};
  int x,y,s,i,j;
  char c;
  int d=0,w=0;
  int S[4]={0,5,9,13};
  int X[]={0,1,-1,0,0,1,-1,1,-1,2,-2,0,0};
  int Y[]={0,0,0,1,-1,1,-1,-1,1,0,0,2,-2};
  while(cin>>x>>c>>y>>c>>s){
    for(i=0;i<S[s];i++){
      
      if(-1<x&&x<10&&-1<y&&y<10){
	if(-1<x+X[i]&&x+X[i]<10&&-1<y+Y[i]&&y+Y[i]<10){
	  k[x+X[i]][y+Y[i]]++;
	  if(k[x+X[i]][y+Y[i]]>d){
	    d=k[x+X[i]][y+Y[i]];
	  }
	}
      }
    }
  }
  for(i=0;i<10;i++){
    for(j=0;j<10;j++){
      if(k[i][j]==0)w++;
    }
  }
  if(d!=0){
    cout<<w<<"\n"<<d<<endl;
  }
  return 0;
}