From 258e1b92ebbfdebefabc120969ab87c3d8b75c3d Mon Sep 17 00:00:00 2001 From: Patrick Simianer Date: Sun, 15 Jun 2014 03:50:12 +0200 Subject: old c,cc examples --- c,cc/cat_char.cc | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 c,cc/cat_char.cc (limited to 'c,cc/cat_char.cc') diff --git a/c,cc/cat_char.cc b/c,cc/cat_char.cc new file mode 100644 index 0000000..3daf564 --- /dev/null +++ b/c,cc/cat_char.cc @@ -0,0 +1,16 @@ +#include +#include + +using namespace std; + + +int main(void) +{ + char c[] = "c"; + char x[1024]; + string s("s"); + strcpy(x, s.c_str()); + strcat(x, c); + cout << x << endl; +} + -- cgit v1.2.3