Skip to main content

Sample C Program to Print a Semicolon without using a Semicolon anywhere in the code.

# include <stdio.h>

int main(void)
// 59 is the ascii value of semicolumn
    if (printf("%c ", 59))
    return 0;


Sample C program to accept an integer and reverse it.

# include <stdio.h>

void main()
    long  num, reverse = 0, temp, remainder;

    printf("Enter the number\n");
    scanf("%ld", &num);
    temp = num;
    while (num > 0)
        remainder = num % 10;
        reverse = reverse * 10 + remainder;
        num /= 10;
    printf("Given number = %ld\n", temp);
    printf("Its reverse is = %ld\n", reverse);


Enter the number
Given number   = 567865
Its reverse is = 568765



Popular posts from this blog

Tell Me Something About Yourself - Interview Answers.

Try to introduce some of your most important employment-oriented skills as well as your education and accomplishments to the interviewer. Answer to this question is very important because it positions you for the rest of the interview. That's why this statement is often called the "Positioning Statement".

One should take the opportunity to show his/her communication skills by speaking clearly and concisely in an organized manner. Since there is no right or wrong answer for this question hence it is important to appear friendly.


1) I am a person with strong interpersonal skills and have the ability to get along well with people. I enjoy challenges and looking for creative solutions to problems.

2) Besides the details given in my resume, I believe in character values, vision and action. I am quick in learning from mistakes. I am confident that the various tests that you have conducted will corroborate my competencies aptitude and right attitude for the…

100 C Programs Frequently Asked in Technical Interview.

100 C++ Programs Frequently Asked in Technical Interview.