From 8d6b3c69b20d74ac7c7c914d4d0cd0a5c80ddbcd Mon Sep 17 00:00:00 2001 From: Ishita15112001 <52873398+Ishita15112001@users.noreply.github.com> Date: Wed, 9 Oct 2019 12:55:20 +0530 Subject: [PATCH] Create input_string_using_pointer.c --- input_string_using_pointer.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+) create mode 100644 input_string_using_pointer.c diff --git a/input_string_using_pointer.c b/input_string_using_pointer.c new file mode 100644 index 0000000..541401f --- /dev/null +++ b/input_string_using_pointer.c @@ -0,0 +1,14 @@ +#include +int main() +{ + int i; + char a[50]; + char *p; + printf("Enter the string : "); + gets(a); + p=a; + while(*p!='\0') + { + printf("%c",*p); + p++; } +}