WHOT IS CHAR?
Answers were Sorted based on User's Feedback
Answer / himaja
n C language, strings are stored in an array of char type along with the null terminating character "\0" at the end. In other words to create a string in C you create an array of chars and set each element in the array to a char value that makes up the string. When sizing the string array you need to add plus one to the actual size of the string to make space for the null terminating character, "\0"
Syntax to declare a string in C:
Sample Code
char fname[4];
Is This Answer Correct ? | 4 Yes | 2 No |
what is difference between array of characters and string
How do I determine whether a character is numeric, alphabetic, and so on?
why do we use pointer instead directly acessing the data?
Explain what is a program flowchart and explain how does it help in writing a program?
pgm to find number of words starting with capital letters in a file(additional memory usage not allowed)(if a word starting with capital also next letter in word is capital cann't be counted twice)
write a program for egyptian fractions in c?
What should malloc() do?
Device an algorithm for weiler-atherton polygon clipping, where the clipping window can be any specified polygon
What are header files in c programming?
Can you please explain the scope of static variables?
How can you find the exact size of a data type in c?
Consider a language that does not have arrays but does have stacks as a data type.and PUSH POP..are all defined .Show how a one dimensional array can be implemented by using two stacks.