Go: package main

import (
	"bufio"
	"os"
	"strings"
	"strconv"
	"fmt"
)

func rangeCheck(x, y int) bool {
	if x >= 0 && x <= 9 && y >= 0 && y <= 9 {
		return true
	} else {
		return false
	}
}

func main() {
	scanner := bufio.NewScanner(os.Stdin)
	paper := make([][]int, 10)
	for i := range paper {
		paper[i] = make([]int, 10)
		for j := range paper[i] {
			paper[i][j] = 0
		}
	}
	fmt.Println(paper)
	for scanner.Scan() {
		infos := strings.Split(scanner.Text(), ",")
		x, _ := strconv.Atoi(infos[0])
		y, _ := strconv.Atoi(infos[1])
		s, _ := strconv.Atoi(infos[2])
		// fmt.Println(x, y, s)
		switch s {
		case 1:
			paper[x][y]++
			if rangeCheck(x, y-1) {
				paper[x][y-1]++
			}
			if rangeCheck(x, y+1) {
				paper[x][y+1]++
			}
			if rangeCheck(x-1, y) {
				paper[x-1][y]++
			}
			if rangeCheck(x+1, y) {
				paper[x+1][y]++
			}
			continue
		case 2:
			paper[x][y]++
			if rangeCheck(x-1, y-1) {
				paper[x-1][y-1]++
			}
			if rangeCheck(x, y-1) {
				paper[x][y-1]++
			}
			if rangeCheck(x+1, y-1) {
				paper[x+1][y-1]++
			}
			if rangeCheck(x-1, y) {
				paper[x-1][y]++
			}
			if rangeCheck(x+1, y) {
				paper[x+1][y]++
			}
			if rangeCheck(x-1, y+1) {
				paper[x-1][y+1]++
			}
			if rangeCheck(x, y+1) {
				paper[x][y+1]++
			}
			if rangeCheck(x+1, y+1) {
				paper[x+1][y+1]++
			}
			continue
		case 3:
			paper[x][y]++
			if rangeCheck(x-1,y-1) {
				paper[x-1][y-1]++
			}
			if rangeCheck(x,y-1) {
				paper[x][y-1]++
			}
			if rangeCheck(x+1,y-1) {
				paper[x+1][y-1]++
			}
			if rangeCheck(x-1,y) {
				paper[x-1][y]++
			}
			if rangeCheck(x+1,y) {
				paper[x+1][y]++
			}
			if rangeCheck(x-1,y+1) {
				paper[x-1][y+1]++
			}
			if rangeCheck(x,y+1) {
				paper[x][y+1]++
			}
			if rangeCheck(x+1,y+1) {
				paper[x+1][y+1]++
			}
			if rangeCheck(x,y-2) {
				paper[x][y-2]++
			}
			if rangeCheck(x-2,y) {
				paper[x-2][y]++
			}
			if rangeCheck(x+2,y) {
				paper[x+2][y]++
			}
			if rangeCheck(x,y+2) {
				paper[x][y+2]++
			}
			continue
		}
	}
	count := 0
	max := -1
	for i := range paper {
		for j := range paper[i] {
			if paper[i][j] == 0 {
				count++
			}
			if max >= paper[i][j] {
				max = max
			} else {
				max = paper[i][j]
			}
		}
	}
	fmt.Printf("%d\n%d", count, max)
}

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;
}

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

int dc[3] = {4,9,13};
int dx[3][13] = {
	{-1,0,-1,0,0},
	{-1,-1,-1,0,0,0,1,1,1},
	{-2,-1,-1,-1,0,0,0,0,0,1,1,1,2}
};
int dy[3][13] = {
	{0,0,0,-1,1},
	{-1,0,1,-1,0,1,-1,0,1},
	{0,-1,0,1,-2,-1,0,1,2,-1,0,1,0}
};

int main(){
	int a,b,c;
	int d[10][10] = {0};
	while(~scanf("%d,%d,%d",&a,&b,&c)){
		c--;
		rep(i,dc[c]){
			int tx = a + dx[c][i] , ty = b + dy[c][i];
			if(tx < 0 || ty < 0 || ty > 9 || tx > 9) continue;
			d[ty][tx]++;
		}
	}
	int white = 0;
	int ans = 0;
	rep(i,10)rep(j,10){
		if(d[i][j]==0)white++;
		else ans = max(d[i][j],ans);
	}
	cout << white << endl << ans << endl;
}

C++: #include<iostream>
#include<stdio.h>
using namespace std;
int main(){
	int a[10][10]={},x,y,size,dumy=0max=0,ans=0;
	int mx[12]={0,-1,1,0,-1,1,-1,1,0,-2,2,0},my[12]={-1,0,0,1,-1,-1,1,1,-2,0,0,2};
	while(scanf("%d,%d,%d",&x,&y,&size)!=EOF){
		dumy=4*size;
		//cout<<size<<endl;
		for(int i=0;i<dumy;i++){
			if(x+mx[i]>=0&&y+my[i]>=0)
			a[x+mx[i]][y+my[i]]++;
		}
	}
	for(int i=0;i<10;i++){
		for(int j=0;j<10;j++){
			if(a[i][j]==0){
				ans++;
			}else{
				if(max<=a[i][j])
				max=a[i][j];
			}
		}
	}
	cout<<ans<<endl<<max<<endl;
return 0;
}