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>
using namespace std;

int main() {
	int pap[10][10];
	for (int i = 0; i < 10; i++) {
		for (int j = 0; j < 10; j++) {
			pap[i][j] = 0;
		}
	}
	int x, y, s;
	int ca = 0;
	int p = 0;
	while (scanf("%d,%d,%d", &x, &y, &s)+1) {

		if (s == 1) {
			pap[x][y] + 1;
			if (x + 1 < 10) { pap[x + 1][y] += 1; }
			if (x - 1 > -1) { pap[x - 1][y] += 1; }
			if (y + 1 < 10) { pap[x][y + 1] += 1; }
			if (y - 1 > -1) { pap[x][y - 1] += 1; }
		}

		if (s == 2) {
			pap[x][y] += 1;
			if (x + 1 < 10) { pap[x + 1][y] += 1; }
			if (x - 1 > -1) { pap[x - 1][y] += 1; }
			if (y + 1 < 10) { pap[x][y + 1] += 1; }
			if (y - 1 > -1) { pap[x][y - 1] += 1; }
			if (x + 1 < 10 && y - 1 > -1) { pap[x + 1][y - 1] += 1; }
			if (x + 1 < 10 && y + 1 < 10) { pap[x + 1][y + 1] += 1; }
			if (x - 1 > -1 && y + 1 < 10) { pap[x - 1][y + 1] += 1; }
			if (x - 1 > -1 && y - 1 > -1) { pap[x - 1][y - 1] += 1; }
		}

			if (s == 3) {
				pap[x][y] += 1;
				if (x + 1 < 10) { pap[x + 1][y] += 1; }
				if (x - 1 > -1) { pap[x - 1][y] += 1; }
				if (y + 1 < 10) { pap[x][y + 1] += 1; }
				if (y - 1 > -1) { pap[x][y - 1] += 1; }
				if (x + 1 < 10 && y - 1 > -1) { pap[x + 1][y - 1] += 1; }
				if (x + 1 < 10 && y + 1 < 10) { pap[x + 1][y + 1] += 1; }
				if (x - 1 > -1 && y + 1 < 10) { pap[x - 1][y + 1] += 1; }
				if (x - 1 > -1 && y - 1 > -1) { pap[x - 1][y - 1] += 1; }
				if (x + 2 < 10) { pap[x + 2][y] += 1; }
				if (x - 2 > -1) { pap[x - 2][y] += 1; }
				if (y + 2 < 10) { pap[x][y + 2] += 1; }
				if (y - 2 > -1) { pap[x][y - 2] += 1; }
			}
		
			for (int i = 0; i < 10; i++) {
				for (int j = 0; j < 10; j++) {
					if (pap[i][j] == 0) { ca++; }
					if (p < pap[i][j]) { p = pap[i][j]; }
				}
			}
	}
	cout << ca << endl << p << endl;
	return 0;
}

C++: #include <cstdio>

int ds[][2]={{0,0},{1,0},{0,1},{-1,0},{0,-1},{1,1},{1,-1},{-1,1},{-1,-1},{2,0},{0,2},{-2,0},{0,-2}};
int map[10][10],kosa,rest=100;

int max(int a,int b){return a>b?a:b;}

int drop(int x,int y){
  if(x>=0 && x<10 && y>=0 && y<10){
    if(map[x][y]++==0) rest--;
    kosa=max(map[x][y],kosa);
  }
}

int main(){
  int x,y,size;
  while(~scanf("%d,%d,%d",&x,&y,&size))
    for(int i=0; i<=4*size; i++)
      drop(x+ds[i][0],y+ds[i][1]);

  printf("%d %d\n",rest,kosa);
}

C++: #include <stdio.h>

int main(){
	int mass[14][14];
	int x,y,size;
	
	int i,j;
	
	int max = 0;
	int n = 0;
	
	for(i = 0;i < 14;i++){
		for(j = 0;j < 14;j++){
			mass[i][j] = 0;
		}
	}
	
	while(scanf("%d,%d,%d",&x,&y,&size) != EOF){
		x += 2;
		y += 2;
		if(size == 1){
			for(i = -1,mass[x][y]--;i < 2;i++){
				mass[x+i][y]++;
				mass[x][y+i]++;
			}
		}else if(size == 2){
			for(i = -1;i < 2;i++){
				for(j = -1;j < 2;j++){
					mass[x+i][y+j]++;
				}
			}
		}else{
			for(i = -1;i < 2;i++){
				for(j = -1;j < 2;j++){
					mass[x+i][y+j]++;
				}
			}
			
			for(i = -2;i <= 2;i += 4){
				mass[x+i][y]++;
				mass[x][y+i]++;
			}
		}
	}
	
	for(i = 2;i < 12;i++){
		for(j = 2;j < 12;j++){
			if(mass[j][i] == 0){
				n++;
			}else if(mass[j][i] > max){
				max = mass[j][i];
			}
		}
	}
	
	printf("%d\n",n);
	printf("%d\n",max);
	
	return 0;
}

C++: #include <iostream>
#include <algorithm>
#include <cstdio>

using namespace std;

int peper[15][15];

void paint(int x, int y)
{
	if (0 <= x && 0 <= y && x >= 9 && y >= 9)	peper[y][x]++;
}

int main()
{
	int x, y;
	int size;
	
	while (scanf("%d,%d,%d", &x, &y, &size) != EOF){
		peper[y][x]++;
		paint(x, y - 1);
		paint(x, y + 1);
		paint(x - 1, y);
		paint(x + 1, y);

		if (size > 1){
			paint(x + 1, y - 1);
			paint(x + 1, y + 1);
			paint(x - 1, y + 1);
			paint(x - 1, y - 1);
		}
		if (size > 2){
			paint(x, y - 2);
			paint(x, y + 2);
			paint(x - 2, y);
			paint(x + 2, y);
		}
	}
	int dark = 0;
	int blank = 0;
	
	for (int i = 0; i < 10; i++){
		for (int j = 0; j < 10; j++){
			if (peper[i][j] == 0)	blank++;
			dark = max(dark, peper[i][j]);
		}
	}
	printf("%d\n%d\n", blank, dark);
	return (0);
}

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

using namespace std;

int p[10][10];
int cnt = 0,Max = 0;
void ink(int x,int y){
  if(0<=x && x < 10|| 0<=y && y<10)p[x][y]++;
}

int main(){

    rep(i,10)rep(j,10){
      p[i][j] = 0;
    }
    int x,y,size;
  while(~scanf("%d,%d,%d",&x,&y,&size)){





    if(size == 1){
      ink(x,y);
      ink(x+1,y);
      ink(x-1,y);
      ink(x,y+1);
      ink(x,y-1);
    }else  if(size == 2){
      ink(x,y);
      ink(x+1,y);
      ink(x-1,y);
      ink(x,y+1);
      ink(x,y-1);
      ink(x+1,y+1);
      ink(x-1,y+1);
      ink(x-1,y-1);
      ink(x+1,y-1);
    }else  if(size == 3){
      ink(x,y);
      ink(x+1,y);
      ink(x-1,y);
      ink(x,y+1);
      ink(x,y-1);
      ink(x+1,y+1);
      ink(x-1,y+1);
      ink(x-1,y-1);
      ink(x+1,y-1);
      ink(x+2,y);
      ink(x-2,y);
      ink(x,y+2);
      ink(x,y-2);
    }
     cnt =Max = 0;
    rep(i,10)rep(j,10){
      if(p[i][j]==0)cnt++;
      Max = max(Max,p[i][j]);
    }
}
    cout << cnt <<"\n" << Max << endl;


  return 0;
}

C++: #include<iostream>
#include<cstdio>

int paper[10][10]={};

void drop(int x,int y){
  if(x>=0&&y>=0&&x<=9&&y<=9){
    ++paper[x][y];
  }
}

void ink(int x,int y, int s){
  switch(s){
    case 3: drop(x+2,y);
            drop(x-2,y);
            drop(x,y+2);
            drop(x,y-2);
    case 2: drop(x+1,y+1);
            drop(x-1,y+1);
            drop(x-1,y-1);
            drop(x+1,y-1);
    case 1: drop(x,y);
            drop(x+1,y);
            drop(x-1,y);
            drop(x,y+1);
            drop(x,y-1);
  }

}

int main(){
  int x,y,s;

  //drop(9,9);

  /*for(int i=0;i<10;i++){
    for(int j=0;j<10;j++){
      std::cout << paper[i][j] << std::endl;
    }
  }*/

  while(std::scanf(" %d,%d,%d",&x,&y,&s)+1){
    //std::cout << x << y << s;
    ink(x,y,s);
  }

  int spase=0,max=0;

  for(int i=0;i<10;i++){
    for(int j=0;j<10;j++){
      if(paper[i][j]==0){
        ++spase;
      }
      if(paper[i][j]>max){
        max = paper[i][j];
      }
    }
  }

  std::cout << spase << std::endl;
  std::cout << max << std::endl;


}