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 <cmath>
#include <vector>


using namespace std;
#define LENGTH 10

bool isDropEnabled(int x, int y){
  if(0<=x && x<LENGTH && 0<=y && y<LENGTH){
    return true;
  }else{
    return false;
  }
}
 



int main(){
  int x, y, size;
  char c;
  int density[LENGTH][LENGTH];
  for(int i=0;i<LENGTH;i++){
    for(int j=0;j<LENGTH;j++){
      density[i][j]=0;
    }
  }
  
  while(cin >> x >> c >> y >> c >> size){
    if(size==1){
      for(int i=-1;i<2;i++){
	for(int j=-1;j<2;j++){
	  if(isDropEnabled(x+i, y+j) && ((i+j)%2==1 || i==j==0)){
	    density[x+i][y+j]++;
	  }
	}
      }
    }

    if(size==2){
      for(int i=-1;i<2;i++){
	for(int j=-1;j<2;j++){
	  if(isDropEnabled(x+i, y+j)){
	    density[x+i][y+j]++;
	  }
	}
      }
    }

    if(size==3){
      for(int i=-2;i<3;i++){
	for(int j=-2;j<3;j++){
	  if(isDropEnabled(x+i, y+j) && (abs(i)+abs(j) <=2)){
	    density[x+i][y+j]++;
	  }
	}
      }
    }
    cout << ":" << x << " " << y << " " << size << endl;
  }

  cout << "out" << endl;

  
  //
  int empty=0;
  int max=0;
  for(int i=0;i<LENGTH;i++){
    for(int j=0;j<LENGTH;j++){
      if(density[i][j]==0){
	empty++;
      }else if(max < density[i][j]){
	max = density[i][j];
      }
    }
  }
  cout << empty << endl;
  cout << max << endl;
  
}

C++: #include <iostream>
using namespace std;

int pa[20][20];

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

	while(true){
		cin >> x;
		if(cin.eof())
			break;
		cin.get();
		if(cin.eof())
			break;
		cin >> y;
		cin.get();
		cin >> c;
		if(cin.eof())
			break;

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

using namespace std;


main(){
  
  int map[10][10];
  int x,y,size;
  //initialize
  for(int i=0;i<10;i++){
    for(int j=0;j<10;j++){
      map[i][j]=0;
    }
  }
  int white=0,Max=0;
  while(scanf("%d,%d,%d",&x,&y,&size)!=EOF){
    
    if(size==1){
      if(x>=0&&x<10&&(y-1)>=0&&(y-1)<10)map[x][y-1]++;    
      if((x-1)>=0&&(x-1)<10&&y>=0&&y<10)map[x-1][y]++;
	 if(x>=0&&x<10&&y>=0&&y<10)map[x][y]++;
	    if((x+1)>=0 &&(x+1)<10&&y>=0&&y<10)map[x+1][y]++;
	       if(x>=0&&x<10&&(y+1)>=0&&(y+1)<10)map[x][y+1]++;
		  
    }
    if(size==2){
      
      if(x-1>=0&&x-1<10&&(y-1)>=0&&(y-1)<10)map[x-1][y-1]++;
      if(x+1>=0&&x+1<10&&(y-1)>=0&&(y-1)<10)map[x+1][y-1]++;
      
      if(x-1>=0&&x-1<10&&(y+1)>=0&&(y+1)<10)map[x-1][y+1]++;
      if(x+1>=0&&x+1<10&&(y+1)>=0&&(y+1)<10)map[x+1][y+1]++;
       if(x>=0&&x<10&&(y-1)>=0&&(y-1)<10)map[x][y-1]++;    
      if((x-1)>=0&&(x-1)<10&&y>=0&&y<10)map[x-1][y]++;
	 if(x>=0&&x<10&&y>=0&&y<10)map[x][y]++;
	    if((x+1)>=0 &&(x+1)<10&&y>=0&&y<10)map[x+1][y]++;
	       if(x>=0&&x<10&&(y+1)>=0&&(y+1)<10)map[x][y+1]++;


    }
    if(size==3){                     if(x>=0&&x<10&&(y-2)>=0&&(y-2)<10) map[x][y-2]++;
                     
       if(x-2>=0&&x-2<10&&(y)>=0&&(y)<10)map[x-2][y]++; if(x+2>=0&&x+2<10&&(y)>=0&&(y)<10)  map[x+2][y]++;
                      
                                     if(x>=0&&x<10&&(y+2)>=0&&(y+2)<10)  map[x][y+2]++;
					  if(x-1>=0&&x-1<10&&(y-1)>=0&&(y-1)<10)map[x-1][y-1]++;
      if(x+1>=0&&x+1<10&&(y-1)>=0&&(y-1)<10)map[x+1][y-1]++;
      
      if(x-1>=0&&x-1<10&&(y+1)>=0&&(y+1)<10)map[x-1][y+1]++;
      if(x+1>=0&&x+1<10&&(y+1)>=0&&(y+1)<10)map[x+1][y+1]++;
       if(x>=0&&x<10&&(y-1)>=0&&(y-1)<10)map[x][y-1]++;    
      if((x-1)>=0&&(x-1)<10&&y>=0&&y<10)map[x-1][y]++;
	 if(x>=0&&x<10&&y>=0&&y<10)map[x][y]++;
	    if((x+1)>=0 &&(x+1)<10&&y>=0&&y<10)map[x+1][y]++;
	       if(x>=0&&x<10&&(y+1)>=0&&(y+1)<10)map[x][y+1]++;
					
    }
    
    
  }

    for(int i=0;i<10;i++){
      for(int j=0;j<10;j++){
	if(map[i][j]==0)white++;
	if(map[i][j]>=Max)Max=map[i][j];
      }
      
    }
  cout << white<<" "<< Max << endl;

  return 0;
}

C++: #include <iostream>

using namespace std;

class Field{
private:
	int v[14][14]; //only 2-11 will be used.
public:
	Field(){
		int i, j;
		for(i=0;i<14;i++){
			for(j=0;j<14;j++){
				v[i][j] = 0;
			}
		}
	}

	void Drop(int x, int y, int s){
		x += 2;
		y += 2;

		if(s == 1){
			v[x][y]++; v[x-1][y]++; v[x+1][y]++; v[x][y-1]++; v[x][y+1]++;
		}else if(s == 2){
			int i, j;
			for(i=x-1;i<=x+1;i++){
				for(j=y-1;j<=y+1;j++){
					v[i][j]++;
				}
			}
		}else{
			int i, j;
			for(i=x-1;i<=x+1;i++){
				for(j=y-1;j<=y+1;j++){
					v[i][j]++;
				}
			}
			v[x-2][y]++; v[x+2][y]++; v[x][y-2]++; v[x][y+2]++;
		}
	}

	void printResult(){
		int i, j;
		int num = 0;
		int max = 0;

		for(i=2;i<=11;i++){
			for(j=2;j<=11;j++){
				if(v[i][j] == 0){
					num++;
				}
				if(max < v[i][j]){
					max = v[i][j];
				}
			}
		}
		cout << num << endl;
		cout << max << endl;
	}
};

int main(void){
	Field field;
	int x, y ,size;

	while(cin >> x){
		cin.ignore();
		cin >> y;
		cin.ignore();
		cin >> size;
		field.Drop(x, y, size);
	}

	field.printResult();
	return 0;
}