HackerRank C- Playing With Characters

You have to print the character, ch , in the first line. Then print s in next line. In the last line print the sentence, sen .

  1. char ch;
  2. scanf("%c",&ch);
  3. char s[20];
  4. scanf("%s",s);
  5. char t;
  6. scanf("%c",&t);
  7. char sen[100];
  8. scanf("%[^\n]",sen);
  9. printf("%c\n",ch);
  10. printf("%s\n",s);
  11. printf("%s\n",sen);
  12. return 0;


Codesadda.com is your home of programming solutions, tutorials, video tutorials and much more. Sign Up for our weekly newsletter to get update about new content.

Like us on Facebook | Connect with us on LinkedIn | Subscribe our Channel on Youtube