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 map[10][10]={};
int sx[] = { 0,-1,1,0 } , sy[] = { -1,0,0,1 } ;
int mx[] = { -1,0,1 }, my[] = { -1,0,1 } ;
int lx[] = { 0,-1,0,1,-2,-1,1,2,-1,0,1,0 } ;
int ly[] = { -2,-1,-1,-1,0,0,0,0,1,1,1,2 } ;

int main(){
	
	int x,y,size ;
	char temp;
	int empty=0,max=0;
	
	while(1){
		cin >> x ;
		if( cin.eof() ) break;
		cin >> temp >> y ;
		cin >> temp >> size ;
		
		map[x][y]++;
		
		if( size==1 ){
			for( int i=0 ; i<4 ; i++ ){
				if( x+sx[i]>=0 && x+sx[i]<=9 && y+sy[i]>=0 && y+sy[i]<=9 )
					map[x+sx[i]][y+sy[i]]++;
			}
		}
		else if( size==2 ){
			for( int i=0 ; i<9 ; i++ ){
				if( x+mx[i%3]>=0 && x+mx[i%3]<=9 && y+my[i/3]>=0 && y+my[i/3]<=9 )
					map[x+mx[i%3]][y+my[i/3]]++;
			}
		}
		else if( size==3 ){
			for( int i=0 ; i<12 ; i++ ){
				if( x+lx[i]>=0 && x+lx[i]<=9 && y+ly[i]>=0 && y+ly[i]<=9 )
					map[x+lx[i]][y+ly[i]]++;
			}
		}
	}
	
	for( int i=0 ; i<10 ; i++ ){
		for( int j=0 ; j<10 ; j++ ){
			if( map[i][j]==0 ) empty++;
			if( map[i][j]>max ) max=map[i][j] ;
		}
	}
	
	cout << empty << endl ;
	cout << max << endl ;
	
return 0;
}

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

int main(void){
  vector < vector <int> > square;
  square.resize(14);
  for(int i=0; (int)i<square.size(); i++){
    square[i].resize(14);
  }
  for(int i=0; i<(int)square.size(); i++){
    for(int j=0; j<(int)square[i].size(); j++){
      square[i][j] =0;
    }
  }

  int x, y, size;
  int min=0, max=0;
  char c;

  while( cin >> x >> c >> y >> c >> size ){
    x+=2;
    y+=2;
    if(size>=1 && size<=3){
      square[y][x]++;
      square[y][x-1]++;
      square[y-1][x]++;
      square[y+1][x]++;
      square[y][x+1]++;
    }
    if(size==2 || size==3){
      square[y-1][x-1]++;
      square[y+1][x-1]++;
      square[y-1][x+1]++;
      square[y+1][x+1]++;
    }
    if(size==3){
      square[y][x-2]++;
      square[y-2][x]++;
      square[y+2][x]++;
      square[y][x+2]++;
    }
  }

  for(int i=2; (int)i<square.size()-2; i++){
    for(int j=2; (int)j<square.size()-2; j++){
      if( square[i][j]==0 ){
        min++;
      }else if(max < square[i][j]){
        max=square[i][j];
      }
    }
  }

  cout << min << 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<stdio.h>
using namespace std;
int main(){
  int dec[10][10];
  int x,y,size,num,max;
  char a;
  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) dec[x+1][y] += 1;
    if(x-1>=0) dec[x-1][y] += 1;
    if(y+1<10) dec[x][y+1] += 1;
    if(x-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)dec[x+2][y] +=1;
      if(x-2>=0)dec[x-2][y] +=1;
      if(y+2<10)dec[x][y+2] +=1;
      if(y-2>=0)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;
}