- Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmain.cpp
More file actions
Latest commit
18 lines (14 loc) · 644 Bytes
/
Copy pathmain.cpp
File metadata and controls
18 lines (14 loc) · 644 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#include<iostream>
#include"commandsDealer.h"
usingnamespacestd;
intmain()
{
int num = 10;
commandsDealer commands;
//algorithmInterface* algorithm = command.getAlgorithm( "DEC" );
cout << "Result (dec): " << commands.getAlgorithm( "DEC" )->execute( num ) << endl;
cout << "Result (bin): " << commands.getAlgorithm( "BIN" )->execute( num ) << endl;
cout << "Result (hex): " << commands.getAlgorithm( "HEX" )->execute( num ) << endl;
cout << "Result (oct): " << commands.getAlgorithm( "OCT" )->execute( num ) << endl;
cout << "Result (bad): " << commands.getAlgorithm( "BAD" )->execute( num ) << endl;
}