- Notifications
You must be signed in to change notification settings - Fork 34
Expand file tree
/
Copy pathexample.cpp
More file actions
Latest commit
40 lines (31 loc) · 677 Bytes
/
Copy pathexample.cpp
File metadata and controls
40 lines (31 loc) · 677 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#include<iostream>
#defineTEXTTABLE_ENCODE_MULTIBYTE_STRINGS
#defineTEXTTABLE_USE_EN_US_UTF8
#include"TextTable.h"
intmain()
{
TextTable t( '-', '|', '+' );
t.add( "" );
t.add( "Sex" );
t.add( "Age" );
t.endOfRow();
t.add( "Moses" );
t.add( "male" );
t.add( "4556" );
t.endOfRow();
t.add( "Jesus" );
t.add( "male" );
t.add( "2016" );
t.endOfRow();
t.add( "Debora" );
t.add( "female" );
t.add( "3001" );
t.endOfRow();
t.add( "Bob Çuçşü" );
t.add( "male" );
t.add( "25" );
t.endOfRow();
t.setAlignment( 2, TextTable::Alignment::RIGHT );
std::cout << t;
return0;
}