How long have use been programming with C++ for?

Myself - I studied c++ for a year at atari. Then going onto java for a year which was pretty horrible. Memory just seems to be all over the place in java hah. Other than that now I'm back to c++ and about to continue my studies with game programming and be finished my studies around about 2 years from now :) So in the long run i still consider myself pretty noobish with c++ but i do enjoy my c# heh
Last edited on
Umm, from when I started learning it, probably about 4-5 yrs, although realistically, it's probably only about 1-2 max.
Same as Firedraco.
I started programming with C++ about 8-9 months ago but I started knowing a bit of the language only after
having found this site :^)
6 months ago.

Almost exactly.

I'm just getting to inheritance.

I feel like such a noob.

*sigh*...
Everyone was there once, I remember when I thought global variables were awesome and that everyone had to be in main (no functions allowed!) XD.
Try this with GCC.
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
#include <stdio.h>

int doit( char* s )
  {
  int insideit( char c )
    {
    int result = 0;
    for (; *s; s++, result++)
      printf( "%c", *s + c );
    return result;
    }

  int n = insideit( 'A' - 'a' );
  printf( "\nn = %d\n", n );
  return n;
  }

int main()
  {
  if (doit( "hello worldA" ) != 12)
    printf( "fooey!\n" );
  else
    printf( "yeah!\n" );
  return 0;
  }

:->
Doesn't compile Duoas :P

1
2
../CMain.cpp: In function `int doit(char*)':
../CMain.cpp:9: error: a function-definition is not allowed here before '{' token 
Use GCC.

(Nested functions are not part of the C language. It is a GNU C extension.)

[edit] Oh, also make sure you aren't compiling with any -pedantic or -std=c89, etc options.

:-P
Last edited on
Woah...I just noticed...

Zaita (1443)
Duoas (1444)
Topic archived. No new replies allowed.