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<string>

enum InkSize
{
	small=0,
	middle,
	large
};

InkSize Next(int x)
{
	if(x<0 || 2<x)
	{
		std::cout << "Input Error.\n";

		return small;
	}

	const InkSize ink[3]=
	{
	small,
	middle,
	large
	};

	return ink[x];
}

struct Board
{
	Board(int a)
	{
		for(size_t i=0; i<m_element; ++i)
		{
			for(size_t j=0; j<m_element; ++j)
			{
				m_map[j][i] = a;
			}
		}
	}
	
	void DropInk(int x, int y, InkSize ink)
	{
		const int inkSet[3][5][5]=
		{
			{//small
				{0,0,0,0,0},
				{0,0,1,0,0},
				{0,1,1,1,0},
				{0,0,1,0,0},
				{0,0,0,0,0},
			},
			{//middle
				{0,0,0,0,0},
				{0,1,1,1,0},
				{0,1,1,1,0},
				{0,1,1,1,0},
				{0,0,0,0,0},
			},
			{//large
				{0,0,1,0,0},
				{0,1,1,1,0},
				{1,1,1,1,1},
				{0,1,1,1,0},
				{0,0,1,0,0},
			}
		};

		for(size_t i=0; i<5; ++i)
		{
			for(size_t j=0; j<5; ++j)
			{
				if( y-2+i<0 || x-2+j<0 || y-2+i>9 || x-2+j>9 )
				{
					continue;
				}

				m_map[y-2+i][x-2+j] += inkSet[ink][i][j];
			}
		}
	}

	int CountNonInkedCell()
	{
		int count=0;

		for(size_t i=0; i<m_element; ++i)
		{
			for(size_t j=0; j<m_element; ++j)
			{
				if(m_map[i][j]==0)
				{
					++count;
				}
			}
		}

		return count;
	}

	int MostInkedCell()
	{
		int max=0;

		for(size_t i=0; i<m_element; ++i)
		{
			for(size_t j=0; j<m_element; ++j)
			{
				if(m_map[i][j]>max)
				{
					max=m_map[i][j];
				}
			}
		}

		return max;
	}

	enum { m_element = 10 };

	int m_map[m_element][m_element];
};

int main()
{
	Board boad1(0);

	int x=0, y=0, inkSize=0;

	char c;

	while(std::cin >> x >> c >> y >> c >> inkSize)
	{
		boad1.DropInk(x,y,Next(inkSize-1));
	}

	std::cout << boad1.CountNonInkedCell() << '\n' << boad1.MostInkedCell() << '\n';

}

C++: #include <iostream>
#include <cstdio>
using namespace std;
int main(){
	int masu[13][13]={0},x,y,s;
	while(scanf("%d,%d,%d",&x,&y,&s)!=EOF){
		x+=2,y+=2;
		if(s==1){
			for(int i=x-1;i<=x+1;i++)masu[i][y]++;
			masu[x][y-1]++;
			masu[x][y+1]++;
		}else if(s==2){
			for(int i=x-1;i<=x+1;i++){
				for(int j=y-1;j<=y+1;j++){
					masu[i][j]++;
				}
			}
		}else{
			for(int i=x-1;i<=x+1;i++){
				for(int j=y-1;j<=y+1;j++){
					masu[i][j]++;
				}
			}
			masu[x-2][y]++,masu[x+2][y]++;
			masu[x][y-2]++,masu[x][y+2]++;
		}
	}
	int siro=0,koi=0;
	for(int i=2;i<=11;i++){
		for(int j=2;j<=11;j++){
			if(masu[i][j]==0)siro++;
			if(koi<masu[i][j])koi=masu[i][j];
		}
	}
	cout<<siro<<endl<<koi<<endl;
	return 0;
}

C++: #include <iostream>
#include <stdio.h>
using namespace std;
int m[10][10];
void small(int x,int y,int r) {
	if (y-r>=0) m[x][y-r]++;
	if (x-r>=0) m[x-r][y]++; 
	if (x+r<=9) m[x+r][y]++;
	if (y+r<=9) m[x][y+r]++;
	m[x][y]++;
}
void middle(int x,int y) {
	for (int i=-1; i<2; i++) for (int j=-1; j<2; j++) 
		if (x+i>=0 && x+i<=9 && y+j>=0 && y+j<=9) m[x+i][y+j]++;
}
void large(int x,int y) {
	middle(x,y);
	small(x,y,2);
    m[x][y]--;
}

int main() {
	int x,y,n,i,j,h,k;
	while(scanf("%d,%d,%d",&x,&y,&n)) {
		if (n==1) small(x,y,1); 
		if (n==2) middle(x,y);
		if (n==3) large(x,y);
	}
    n=0; h=0; k=0;
	for (i=0;i<10;i++) for (j=0;j<10;j++) {
		if (m[i][j]==0) k++; else h=h<m[i][j] ? m[i][j] : h;
	}
    cout << k << endl << h << endl;
	return 0;
	}

C++: #include <iostream>
#include <fstream>
#include <algorithm>
#include <vector>
#include <string>
#include <functional>
#include <array>
#include <stack>
#include <queue>
#include <chrono>
#include <numeric>
#include <memory.h>
#include <map>
#include <math.h>
#include <utility>
#include <set>

#pragma warning(disable:4996)
using namespace std;
#define REP(i,n) for(int i = 0 ; i < n ; ++i)
typedef long long Int;
const double PI = 3.141592653589793238;
const Int INF = 999999999999;
typedef pair<int, int> P;

int S[3][3] = {
		{ 0, 1, 0 },
		{ 1, 1, 1 },
		{ 0, 1, 0 },
};
int M[3][3] = {
		{ 1, 1, 1 },
		{ 1, 1, 1 },
		{ 1, 1, 1 },
};
int L[5][5] = {
		{ 0, 0, 1, 0, 0 },
		{ 0, 1, 1, 1, 0 },
		{ 1, 1, 1, 1, 1 },
		{ 0, 1, 1, 1, 0 },
		{ 0, 0, 1, 0, 0 },
};

int tile[10][10];

int main()
{
	int x, y, size;
	while (scanf("%d,%d,%d",&x,&y,&size)){
		int xt = x;
		int yt = y;
		if (size == 1){
			while (xt - 1 < 0)++xt;
			while (yt - 1 < 0)++yt;
			while (xt + 2 > 9)--xt;
			while (yt + 2 > 9)--yt;

			for (int i = yt - 1; i < yt + 2; ++i){
				for (int j = xt - 1; j < xt + 2; ++j){
					tile[i][j] += S[i + 1 - yt][j + 1 - xt];
				}
			}
		}
		if (size == 2){
			while (xt - 1 < 0)++xt;
			while (yt - 1 < 0)++yt;
			while (xt + 2 > 9)--xt;
			while (yt + 2 > 9)--yt;

			for (int i = yt - 1; i < yt + 2; ++i){
				for (int j = xt - 1; j < xt + 2; ++j){
					tile[i][j] += M[i + 1 - yt][j + 1 - xt];
				}
			}

		}
		if (size == 3){
			while (xt - 1 < 0)++xt;
			while (yt - 1 < 0)++yt;
			while (xt + 3 > 9)--xt;
			while (yt + 3  > 9)--yt;

			for (int i = yt - 2; i < yt + 3; ++i){
				for (int j = xt - 2; j < xt + 3; ++j){
					tile[i][j] += L[i + 2 - yt][j + 2 - xt];
				}
			}

		}
	}
	int white = 0;
	int max_ = -1;

	REP(i, 10){
		REP(j, 10){
			if (!tile[i][j])
				++white;
			max_ = max(tile[i][j], max_);
		}
	}

	cout << white << endl << max_ << endl;

	return 0;

}