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<bits/stdc++.h>
#include<vector>
#include<list>
#include<stack>
#include<queue>
#include<algorithm>
using namespace std;

int main(){
    int mod=1000000007;
    int a[10][10];
    for (int i=0;i<10;i++) {
        for (int j=0;j<10;j++) {
            a[i][j]=0;
        }
    }
    int x,y,s;
    int ans[2]={100,0};
    while (scanf("%d,%d,%d",&x,&y,&s)!=EOF) {
        a[y][x]+=1;
        if (y>0) a[y-1][x]+=1;
        if (x>0) a[y][x-1]+=1;
        if (y<9) a[y+1][x]+=1;
        if (x<9) a[y][x+1]+=1;

        if (s>=2) {
            if (y>0 && x>0) a[y-1][x-1]+=1;
            if (y>0 && x<9) a[y-1][x+1]+=1;
            if (y<9 && x>0) a[y+1][x-1]+=1;
            if (y<9 && x<9) a[y+1][x+1]+=1;
        }

        if (s==3) {
            if (y>1) a[y-2][x]+=1;
            if (x>1) a[y][x-2]+=1;
            if (y<8) a[y+2][x]+=1;
            if (x<8) a[y][x+2]+=1;
        }
    }

    for (int i=0;i<10;i++) {
        for (int j=0;j<10;j++) {
            if (a[i][j]!=0) {
                ans[0]-=1;
                ans[1]=max(ans[1],a[i][j]);
            }
        }
    }
    printf("%d\n%d\n",ans[0],ans[1]);
    return 0;
}

C++: #include <iostream>
#include <string>
#include <vector>
#include <cmath>
#include <algorithm>
#include <cstdlib>
#include <ctime>
#include <cstdio>
#include <functional>
#include <complex>
using namespace std;
int main() {
	int paper[14][14] = { 0 };
	int fl, x, y;
	char split;
	while (cin >> y>> split >> x >> split >> fl) {
		if (fl == 2) {
			for (int i = 0;i < 3;i++) {
				for (int j = 0;j < 3;j++) {
					paper[x + 1 + i][y + 1 + j] += 1;
				}
			}
		}
		if (fl == 1) {
			paper[x + 2][y + 2] += 1;
			paper[x + 1][y + 2] += 1;
			paper[x + 2][y + 1] += 1;
			paper[x + 3][y + 1] += 1;
			paper[x + 1][y + 3] += 1;
		}
		if (fl == 3) {
			for (int i = 0;i < 3;i++) {
				for (int j = 0;j < 3;j++) {
					paper[x + 1 + i][y + 1 + j] += 1;
				}
			}
				paper[x][y + 2] += 1;
				paper[x + 4][y + 2] += 1;
				paper[x + 2][y + 4] += 1;
				paper[x + 2][y] += 1;
			
		}
		int count = 0;
		int ans = 0;
		for (int i = 2;i < 12;i++) {
			for (int j = 2;j < 12;j++) {
				if (paper[i][j] == 0) count += 1;
				ans = max(ans, paper[i][j]);
			}
		}
		cout << count << endl;
		cout << ans << endl;
	}
}

C++: #include <iostream>
#include <vector>
#include <map>

class DrawAreaStrategy
{
public:
	DrawAreaStrategy(){}
	virtual ~DrawAreaStrategy(){}

	DrawAreaStrategy(const DrawAreaStrategy&) = delete;
	DrawAreaStrategy& operator=(const DrawAreaStrategy&) = delete;

	DrawAreaStrategy(DrawAreaStrategy&&) = delete;
	DrawAreaStrategy& operator=(DrawAreaStrategy&&) = delete;

	virtual void Draw(std::vector<std::vector<int>>& draw_sheet, int x, int y) = 0;
};

class DrawAreaSmallStrategy
{
public:
	DrawAreaSmallStrategy() {}
	virtual ~DrawAreaSmallStrategy() {}

	DrawAreaSmallStrategy(const DrawAreaSmallStrategy&) = delete;
	DrawAreaSmallStrategy& operator=(const DrawAreaSmallStrategy&) = delete;

	DrawAreaSmallStrategy(DrawAreaSmallStrategy&&) = delete;
	DrawAreaSmallStrategy& operator=(DrawAreaSmallStrategy&&) = delete;

	virtual void Draw(std::vector<std::vector<int>>& draw_sheet, int x, int y)
	{
		static const std::vector<std::pair<int, int>> draw_list
		{
			{ 0,  0 },

			{ -1,  0 },
			{  1,  0 },
			{  0, -1 },
			{  0,  1 }
		};
		for (auto draw_point : draw_list)
		{
			draw_sheet[x + draw_point.first][y + draw_point.second]++;
		}
	}
};


class DrawAreaMiddleStrategy
{
public:
	DrawAreaMiddleStrategy() {}
	virtual ~DrawAreaMiddleStrategy() {}

	DrawAreaMiddleStrategy(const DrawAreaMiddleStrategy&) = delete;
	DrawAreaMiddleStrategy& operator=(const DrawAreaMiddleStrategy&) = delete;

	DrawAreaMiddleStrategy(DrawAreaMiddleStrategy&&) = delete;
	DrawAreaMiddleStrategy& operator=(DrawAreaMiddleStrategy&&) = delete;

	virtual void Draw(std::vector<std::vector<int>>& draw_sheet, int x, int y)
	{
		static const std::vector<std::pair<int, int>> draw_list
		{
			{ 0,  0 },

			{ -1,  0 },
			{ 1,  0 },
			{ 0, -1 },
			{ 0,  1 },

			{ -1, -1 },
			{ -1,  1 },
			{  1, -1 },
			{  1,  1 }
		};
		for (auto draw_point : draw_list)
		{
			draw_sheet[x + draw_point.first][y + draw_point.second]++;
		}
	}
};

class DrawAreaLargeStrategy
{
public:
	DrawAreaLargeStrategy() {}
	virtual ~DrawAreaLargeStrategy() {}

	DrawAreaLargeStrategy(const DrawAreaLargeStrategy&) = delete;
	DrawAreaLargeStrategy& operator=(const DrawAreaLargeStrategy&) = delete;

	DrawAreaLargeStrategy(DrawAreaLargeStrategy&&) = delete;
	DrawAreaLargeStrategy& operator=(DrawAreaLargeStrategy&&) = delete;

	virtual void Draw(std::vector<std::vector<int>>& draw_sheet, int x, int y)
	{
		static const std::vector<std::pair<int, int>> draw_list
		{
			{  0,  0 },

			{ -1,  0 },
			{  1,  0 },
			{  0, -1 },
			{  0,  1 },

			{ -1, -1 },
			{ -1,  1 },
			{  1, -1 },
			{  1,  1 },

			{ -2,  0 },
			{  2,  0 },
			{  0, -2 },
			{  0,  2 }
		};
		for (auto draw_point : draw_list)
		{
			draw_sheet[x + draw_point.first][y + draw_point.second]++;
		}
	}
};

int main()
{
	DrawAreaSmallStrategy small;
	DrawAreaMiddleStrategy middle;
	DrawAreaLargeStrategy large;

	std::vector< std::vector<int> > sheet(10, std::vector<int>(10));

	int x = 0, y = 0, s = 0;
	char a = 0;
	while (std::cin >> x >> a >> y >> a >> s)
	{
		//switch (s)
		//{
		//case 1:
		//{
		//	small.Draw(sheet, x, y);
		//	break;
		//}
		//case 2:
		//{
		//	middle.Draw(sheet, x, y);
		//	break;
		//}
		//case 3:
		//{
		//	large.Draw(sheet, x, y);
		//	break;
		//}
		//default:
		//	break;
		//}
	}

	int empty_num = 0;
	int max_num = 0;

	for (auto line : sheet)
	{
		for (auto cell : line)
		{
			if (0 == cell)
			{
				empty_num++;
				continue;
			}
			if (max_num < cell)
			{
				max_num = cell;
			}
		}
	}
	std::cout << empty_num << "\n" << max_num << std::endl;

	return 0;
}