About 326,000 results
Open links in new tab
  1. Difference between char* and char** (in C) - Stack Overflow

    } int main() { char *s = malloc(5); // s points to an array of 5 chars modify(&s); // s now points to a new array of 10 chars free(s); } You can also use char ** to store an array of strings. However, …

  2. British usage of “cha”, “char” or “chai” to mean “tea”

    By happenstance, I stumbled upon the words cha, char and chai in the dictionary today, all defined as meaning tea in informal British English. I lived and worked in London for some time, …

  3. c - char *array and char array [] - Stack Overflow

    char *array = "One good thing about music"; declares a pointer array and make it point to a (read-only) array of 27 characters, including the terminating null-character.

  4. Difference between char and char* in c - CS50 Stack Exchange

    Feb 24, 2015 · The difference between char* the pointer and char[] the array is how you interact with them after you create them. If you are just printing the two examples, it will perform …

  5. c++ - char and char* (pointer) - Stack Overflow

    For cout << &q - operator << (ostream&, char* p) expects that p points to NULL terminated string - and &q points to memory containing "H" but what is after this character no one knows - so you …

  6. comparison between pointer and integer ('const char' and 'char')

    Dec 5, 2022 · Each element of the alphabet array is a char * ( a char pointer aka a string). One possible solution would be to change the alphabet array to a char array (and all the double …

  7. c - What is the difference between char s - Stack Overflow

    Nov 10, 2009 · char *s = "hello"; So what is the difference? I want to know what actually happens in terms of storage duration, both at compile and run time.

  8. c - incompatible pointer types passing 'string' (aka 'char *') to ...

    Jul 14, 2020 · The function does not, in fact, take " string as a argument ". It takes an array of strings as the argument. That is what this notation [] denotes.

  9. c++ - What is a char*? - Stack Overflow

    The char type can only represent a single character. When you have a sequence of characters, they are piled next to each other in memory, and the location of the first character in that …

  10. How to convert an unsigned char to a string? - CS50 Stack Exchange

    Sep 20, 2021 · The code is essentially correct. The problem is the data that you chose to put in byte_loop [10]. It's pretty much all unprintable or invalid ASCII codes. Try using 0x61 through …