rg3 / cifras

Program to solve the numeric problems from the Spanish TV show "Cifras y Letras"

This URL has Read+Write access

cifras / operation.cc
100644 18 lines (14 sloc) 0.343 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/*
* Author: Ricardo Garcia Gonzalez
* License: Public domain code
*/
#include <iostream>
#include <limits>
 
#include "operation.h"
 
using std::ostream;
 
// Output a given operation.
ostream &operator<<(ostream &out, const Operation &op)
{
return out << op.left() << ' ' << op.opchar() << ' ' << op.right()
<< " = " << op.result();
}