Search:

Type: Posts; User: Confuzero

Search: Search took 0.00 seconds.

  1. Function - allocate new string and copy X characters

    I'm supposed to write a function that receives a string and a number X as arguments, allocates a 2nd string of minimum length and copies first X characters of 1st string to the 2nd string and returns...
  2. Replies
    4
    Views
    3,669

    Great! Thanx to both of you.

    Great! Thanx to both of you.
  3. Replies
    4
    Views
    3,669

    Thanx for the answer, grumpy, I think I get it,...

    Thanx for the answer, grumpy, I think I get it, but let me review, just to be sure.

    "c = '1' + 1;" means you add 1 to the character '1' so it becomes '2', and numerical value of '2' --> 50
    ...
  4. Replies
    4
    Views
    3,669

    Char and switch output

    Hi, could anybody explain to me why the code below outputs "5050"? I'm having huuuge problems understanding the whole deal with char. I just don't get it at all.

    The way I see it, "c = '1' + 1;"...
Results 1 to 4 of 4