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;


main(){
  
  int map[10][10];
  int x,y,size;
  //initialize
  for(int i=0;i<10;i++){
    for(int j=0;j<10;j++){
      map[i][j]=0;
    }
  }
  int white=0,Max=0;
  while(scanf("%d,%d,%d",&x,&y,&size)!=EOF){
    
    if(size==1){
      if(y>=0&&y<10&&(x-1)>=0&&(x-1)<10)map[y][x-1]++;    
      if((y-1)>=0&&(y-1)<10&&x>=0&&x<10)map[y-1][x]++;
	 if(y>=0&&y<10&&x>=0&&x<10)map[y][x]++;
	    if((y+1)>=0 &&(y+1)<10&&x>=0&&x<10)map[y+1][x]++;
	       if(y>=0&&y<10&&(x+1)>=0&&(x+1)<10)map[y][x+1]++;
		  
    }
    if(size==2){
      
      if(y-1>=0&&y-1<10&&(x-1)>=0&&(x-1)<10)map[y-1][x-1]++;
      if(y+1>=0&&y+1<10&&(x-1)>=0&&(x-1)<10)map[y+1][x-1]++;
      
      if(y-1>=0&&y-1<10&&(x+1)>=0&&(x+1)<10)map[y-1][x+1]++;
      if(y+1>=0&&y+1<10&&(x+1)>=0&&(x+1)<10)map[y+1][x+1]++;
       if(y>=0&&y<10&&(x-1)>=0&&(x-1)<10)map[y][x-1]++;    
      if((y-1)>=0&&(y-1)<10&&x>=0&&x<10)map[y-1][x]++;
	 if(y>=0&&y<10&&x>=0&&x<10)map[y][x]++;
	    if((y+1)>=0 &&(y+1)<10&&x>=0&&x<10)map[y+1][x]++;
	       if(y>=0&&y<10&&(x+1)>=0&&(x+1)<10)map[y][x+1]++;


    }
    if(size==3){                     if(y>=0&&y<10&&(x-2)>=0&&(x-2)<10) map[y][x-2]++;
                     
       if(y-2>=0&&y-2<10&&(x)>=0&&(x)<10)map[y-2][x]++; if(y+2>=0&&y+2<10&&(x)>=0&&(x)<10)  map[y+2][x]++;
                      
                                     if(y>=0&&y<10&&(x+2)>=0&&(x+2)<10)  map[y][x+2]++;
					  if(y-1>=0&&y-1<10&&(x-1)>=0&&(x-1)<10)map[y-1][x-1]++;
      if(y+1>=0&&y+1<10&&(x-1)>=0&&(x-1)<10)map[y+1][x-1]++;
      
      if(y-1>=0&&y-1<10&&(x+1)>=0&&(x+1)<10)map[y-1][x+1]++;
      if(y+1>=0&&y+1<10&&(x+1)>=0&&(x+1)<10)map[y+1][x+1]++;
       if(y>=0&&y<10&&(x-1)>=0&&(x-1)<10)map[y][x-1]++;    
      if((y-1)>=0&&(y-1)<10&&x>=0&&x<10)map[y-1][x]++;
	 if(y>=0&&y<10&&x>=0&&x<10)map[y][x]++;
	    if((y+1)>=0 &&(y+1)<10&&x>=0&&x<10)map[y+1][x]++;
	       if(y>=0&&y<10&&(x+1)>=0&&(x+1)<10)map[y][x+1]++;
					
    }
    
    
  }

    for(int i=0;i<10;i++){
      for(int j=0;j<10;j++){
	if(map[i][j]==0)white++;
	if(map[i][j]>=Max)Max=map[i][j];
      }
      
    }
  cout << white<<" "<< Max << endl;

  return 0;
}

C++: #include <bits/stdc++.h>

using namespace std;

int main()
{
    int x, y, s;
    char c;
    vector<vector<int>> v(14, vector<int>(14, 0));
    while (cin >> x >> c >> y >> c >> s) {
        x += 2; y += 2;
        switch (s) {
            case 3:
                v[x][y-2]++; v[x][y+2]++;
                v[x-2][y]++; v[x+2][y]++;
            case 2:
                v[x-1][y-1]++; v[x-1][y+1]++;
                v[x+1][y-1]++; v[x+1][y+1]++;
            case 1:
                v[x+1][y]++; v[x-1][y]++;
                v[x][y-1]++; v[x][y+1]++;
                v[x][y]++;
                break;
        }
    }
    
    int mx = 0, cnt = 0;
    for (int i = 2; i < 12; i++) {
        for (int j = 2; j < 12; j++) {
            mx = max(mx, v[i][j]);
            if (v[i][j] == 0) cnt++;
        }
    }
    cout << cnt << "\n" << mx << endl;
    return 0;
}

C++: #include<iostream>
#include<algorithm>
#include<cstdio>
#include<cstdlib>
#include<vector>
#include<map>
#include<queue>
#include<string>
#include<sstream>
#include<cmath>
#include<numeric>
#include<random>
using namespace std;

int main(){

  int s3x[12] = {0, 1, 0, -1, 1, 1, -1, -1, 0, 2, 0, -2};
  int s3y[12] = {1, 0, -1, 0, 1, -1, 1, -1, 2, 0, -2, 0};

  vector< vector<int> > p( 10, vector<int> (10, 0) );
  int x, y, s;
  int cnt = 0;
  int mx = 0;

  while( scanf("%d,%d,%d", &x, &y, &s) != EOF ){
    p[ x ][ y ]++;
    cnt++;
    for(int i=0; i<s*4; i++){
      int tx = x + s3x[i];
      int ty = y + s3y[i];
      if( tx < 0 || ty < 0 || tx >= 10 || ty >= 10 ) continue;
      p[tx][ty]++;
      cnt++;
      mx = max(mx, p[tx][ty]);
    }
    // cerr << cnt << endl;
  }
  cout << cnt << endl;
  cout << mx << endl;
  return 0;
}




// EOF

C++: #include <iostream>
#include <string>
#include <vector>
#include <cstdlib>

#define REP(i,k,n) for(int i=k;i<n;i++)
#define rep(i,n) for(int i=0;i<n;i++)

using namespace std;

vector<string> split(const string &str, char delim)
{
  vector<string> res;
  size_t current = 0, found;
  while((found = str.find_first_of(delim, current)) != string::npos)
  {
    res.push_back(string(str, current, found - current));
    current = found + 1;
  }
  res.push_back(string(str, current, str.size() - current));
  return res;
}

int f[10][10];

bool checkf(int x,int y)
{
	if(0 <= x && x < 10 && 0 <= y && y < 10)
	{
		return true;
	}
	else
	{
		return false;
	}
}

void dropInk(int x,int y,int size)
{
	if(size == 1)
	{
		f[x][y]++;
		if(checkf(x+1,y)) f[x+1][y]++;
		if(checkf(x-1,y)) f[x-1][y]++;
		if(checkf(x,y+1)) f[x][y+1]++;
		if(checkf(x,y-1)) f[x][y-1]++;
	}
	else if(size == 2)
	{
		REP(i,-1,2)
		{
			REP(j,-1,2)
			{
				if(checkf(x+i,y+j)) f[x+i][y+j]++;
			}
		}
	}
	else if(size == 3)
	{
		REP(i,-1,2)
		{
			REP(j,-1,2)
			{
				if(checkf(x+i,y+j)) f[x+i][y+j]++;
			}
		}
		if(checkf(x+2,y)) f[x+2][y]++;
		if(checkf(x-2,y)) f[x-2][y]++;
		if(checkf(x,y+2)) f[x][y+2]++;
		if(checkf(x,y-2)) f[x][y-2]++;
	}
}

int main()
{
	memset(f,0,sizeof(f));
	string s;
	while(cin >> s)
	{
		vector<string> _s = split(s,',');
		int x = atoi(_s[0].c_str());
		int y = atoi(_s[1].c_str());
		int size = atoi(_s[2].c_str());

		dropInk(y,x,size);
	}

	int count = 0;
	int ans = 0;
	rep(i,10)
	{
		rep(j,10)
		{
			if(f[i][j] == 0)
			{
				count++;
			}
			ans = max(ans,f[i][j]);
		}
	}

	cout << count << endl << ans << endl;
	return 0;
}