Interviews Questions, Algorithms, Aptitude, C Interview Program, C Theory Question, Aptitude Tricks, Test Series,

Thursday, 28 March 2019

Print characters without using format specifiers

Question:

C program to print characters without using format specifiers

C Program:

// Prints characters without format specifiers
#include <stdio.h>

int main()
{
  //ASCII Values
  printf("\x41 \n");
    printf("\x4d \n");
    printf("\x49 \n");
    printf("\x54");
    return 0;
}

Output:
A
M
 I
T

0 comments:

Post a Comment