Type your name at the keyboard and then have the computer display your name on the screen, along with friendly greeting - C Language Basics

C examples for Language Basics:scanf

Description

Type your name at the keyboard and then have the computer display your name on the screen, along with friendly greeting

Demo Code

#include <stdio.h>
int main()//from   www  .  j a  va  2s  . c o  m
{
   char me[20];
   printf("What is your name?");
   scanf("%s",&me);
   printf("Darn glad to meet you, %s!\n",me);
   return(0);
}

Result


Related Tutorials