Strings in C
An array of characters in C Language is called Strings. The null character also has a role in C language. A string is terminated by a null character i.e. \0. In this lesson, we will learn how to work with Strings in C programming.
Let’s first see what we meant by strings. The following is a string,
You can also declare and initialize the above string like the following, with extra space for the null character and size in square brackets,
he array structure looks like the following with characters,
In this lesson, we learned how to declare and initialize Strings in C programming with some examples.
If you liked the tutorial, spread the word and share the link and our website LANGUAGE CODING with others.
0 comments:
Post a Comment