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

int pa[20][20];

int main(void)
{
	int x,y,c;

	while(scanf("%d,%d,%d", &x,&y,&c) != EOF){

		if(c == 1){
			for(int i = -1; i <= 1; i++){
				pa[y][x-i]++;
				pa[y-i][x]++;

			}
			pa[y][x]--;
		}
		else if(c == 2){
			for(int i = -1; i <= 1; i++){
				for(int j = -1; j <= 1; j++)
					pa[y-i][x-j]++;
			}
		}
		else if(c == 3){
			for(int i = -1; i <= 1; i++){
				for(int j = -1; j <= 1; j++)
					pa[y-i][x-j]++;
			}
			pa[y+2][x+2]++;
			pa[y+2][x-2]++;
			pa[y-2][x-2]++;
			pa[y-2][x+2]++;
		}	
	}

	int count = 0, max = 0;

	for(int i = 1; i <= 10; i++){
		for(int j = 1; j <= 10; j++){
			if(pa[i][j])
				count++;
			if(max < pa[i][j])
				max = pa[i][j];
		}
	}
	count = 100 - count;
	cout << count << endl << max << endl;


	return 0;
}

C++: #include <bits/stdc++.h>
using namespace std ;

#define pb(n) push_back(n)
#define fi first
#define se second
#define all(r) (r).begin(),(r).end()
#define gsort(st,en) sort((st),(en),greater<int>())
#define vmax(ary) *max_element(all(ary))
#define vmin(ary) *min_element(all(ary))
#define debug(x) cout<<#x<<": "<<x<<endl
#define fcout(n) cout<<fixed<<setprecision((n))
#define scout(n) cout<<setw(n)
#define vary(type,name,size,init) vector< type> name(size,init)

#define rep(i,n) for(int i = 0; i < (int)(n);++i)
#define REP(i,a,b) for(int i = (a);i < (int)(b);++i)
#define repi(it,array) for(auto it = array.begin(),end = array.end(); it != end;++it)
#define repa(n,array) for(auto &n :(array))

using ll = long long;
using vi = vector<int>;
using vl = vector<ll>;
using dict = map<string,int>;
using comd = complex<double>;
using pii = pair<int,int> ;

constexpr int imax = ((1<<30)-1)*2+1 ;
constexpr int inf = 100000000;
constexpr double PI = acos(-1.0) ;
double eps = 1e-10 ;
const int dy[] = {-1,0,1,0};
const int dx[] = {0,-1,0,1};

inline bool value(int x,int y,int w,int h){
  return (x >= 0 && x < w && y >= 0 && y < h);
}
template<typename T>
void Unique(vector<T> &v){
  sort(all(v));
  v.erase(all(v),v.end());
}

template<typename T>
T ston(string& str, T n){
  istringstream sin(str) ;
  T num ;
  sin >> num ;
  return num ;
}

void Ans(bool f){
  if(f) cout << "YES"<<endl;
  else cout << "NO"<<endl;
}
int dx2[] = {1,1,1,-1,-1,-1,0,0};
int dy2[] = {1,0,-1,-1,0,1,1,-1};
int m[10][10];
int main(){
  cin.tie(0);
  ios::sync_with_stdio(false);
  char c;
  int x,y,s,a1 = 100,a2 = 0;
  while(cin>>x>>c>>y>>c>>s){
    if(s == 1){
      if(m[x][y] == 0)
        --a1;
      m[x][y]++;
      rep(i,4){
        int X = x+dx[i],Y=y+dy[i];
        if(value(x+dx[i],y+dy[i],10,10)){
          if(m[X][Y] == 0)
            --a1;
          m[x+dx[i]][y+dy[i]]++;
          if(m[X][Y] > a2){
            a2 = m[X][Y];
          }
        }
      }
    }
    else if(s == 2){
      if(m[x][y] == 0)
        --a1;
      m[x][y]++;
      rep(i,8){
        int X = x+dx2[i],Y=y+dy2[i];
        if(value(x+dx2[i],y+dy2[i],10,10)){
          if(m[X][Y] == 0)
            --a1;
          m[x+dx2[i]][y+dy2[i]]++;
          if(m[X][Y] > a2){
            a2 = m[X][Y];
          }
        }
      }
    }
    else{
      if(m[x][y] == 0)
        --a1;
      m[x][y]++;
      rep(i,8){
        int X = x+dx2[i],Y=y+dy2[i];
        if(value(X,Y,10,10)){
          if(m[X][Y] == 0)
            --a1;
          m[X][Y]++;
          if(m[X][Y] > a2){
            a2 = m[X][Y];
          }
        }
      }
      rep(i,4){
        int X = x+dx[i]*2,Y=y+dy[i]*2;
        if(value(X,Y,10,10)){
          if(m[x+dx[i]*2][y+dy[i]*2] == 0)
            --a1;
          m[x+dx[i]*2][y+dy[i]*2]++;
          if(m[X][Y] > a2){
            a2 = m[X][Y];
          }
        }
      }
    }
  }
  cout << a1 << endl;
  cout << a2 <<endl;
  return 0;
}

C++: import java.util.Scanner;
 
public class Main {
 static int     max   = 0;
 static int     count = 100;
 static int[][] p     = new int[10][10];
 
 public static void main(String[] args) {
    Scanner in = new Scanner(System.in)
      .useDelimiter("[^0-9]+");
    max = 0;
    count = 100;
    for (int i = 0; i < p.length; i++) {
     for (int j = 0; j < p[i].length; j++) {
        p[i][j] = 0;
     }
    }
    while (in.hasNextLine()) {
     ink(in.nextInt(), in.nextInt(), in.nextInt());
    }
    System.out.println(count);
    System.out.println(max);
 
 }
 
 static void ink(int x, int y, final int size) {
    if (size >= 3) {
     pi(x + 2, y);
     pi(x - 2, y);
     pi(x, y + 2);
     pi(x, y - 2);
    }
    if (size >= 2) {
     pi(x + 1, y + 1);
     pi(x + 1, y - 1);
     pi(x - 1, y + 1);
     pi(x - 1, y - 1);
    }
    if (size >= 1) {
     pi(x + 1, y);
     pi(x - 1, y);
     pi(x, y + 1);
     pi(x, y - 1);
    }
    pi(x, y);
 }
 
 static void pi(int x, int y) {
    if (0 <= x && x < 10 && 0 <= y && y < 10) {
     if (p[x][y] == 0) {
        count--;
     }
     p[x][y]++;
     max = Math.max(max, p[x][y]);
    }
 }
}

C++: #include <iostream>

#define SIZE 10

using namespace std;

int map[SIZE][SIZE] = {0};

void drop(int x, int y) {
	if (x < 0 || y < 0 || x >= SIZE || y >= SIZE) return;

	map[x][y]++;
	return;
}

int main() {
	int x, y, s, count = 0, most = 0;
	char e;
	while (cin>>x>>e>>y>>e>>s) {
		x--;
		y--;
		drop(x, y);
		drop(x, y + 1);
		drop(x + 1, y);
		drop(x, y - 1);
		drop(x - 1, y);

		if (s > 1) {
			drop(x + 1, y + 1);
			drop(x + 1, y - 1);
			drop(x - 1, y - 1);
			drop(x - 1, y + 1);

			if (s > 2) {
				drop(x, y + 2);
				drop(x, y - 2);
				drop(x + 2, y);
				drop(x - 2, y);
			}
		}
	}

	for (int i = 0; i < SIZE; i++) {
		for (int j = 0; j < SIZE; j++) {
			if (map[i][j] > most) {
				most = map[i][j];
			}

			if (map[i][j] == 0) {
				count++;
			}
		}
	}

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