How to iterate over a string in C?

C Programming Language String functions in C (Article) String functions in C (Program)

376

Program:

#include<stdio.h>
#include<string.h>
int main()
{
int i;
char a[] = "Rumman Ansari";

    for(i = 0; i < strlen(a); i++)
    {
    printf("%c", a[i]);
    }

}

Output:

Rumman Ansari

Explanation:

No

This Particular section is dedicated to Programs only. If you want learn more about C Programming Language. Then you can visit below links to get more depth on this subject.