by Dinesh Thakur

This is c program that user has to show how to enter the content through string copy function. User declare array type variable so that use to contain the data in it. Here user declares the strcpy function to initialize the name as content. In the last user display the print method to show the output in result.

Problem statement:
This is C program to define the String copy function.

  1. Declare the variables.
  2. Using function.
  3. Display result on the screen.

Here is C source code to enter through string function. The output of this program shown below.

#include <string.h>
#include <stdio.h>
char name[30];    /* First name of someone */
int main()
    strcpy(name, "Sam");    /* Initialize the name */
    printf("The name is %s\n", name);
    return (0);

Write a Program with Enter Through Strcpy