About 23,100 results
Open links in new tab
  1. C programming is a powerful language that provides a foundation for many modern programming languages. Here are some examples of basic and advanced C programs to help you understand and practice C programming concepts.

    Basic C Programs

    Hello World Program

    The simplest program in C is the "Hello, World!" program. It prints the message "Hello, World!" to the screen.

    #include <stdio.h>

    int main() {
    printf("Hello, World!\n");
    return 0;
    }
    Copied!

    This program uses the printf function to display the message on the screen.

    Add Two Numbers

    This program takes two integers as input from the user and prints their sum.

    #include <stdio.h>

    int main() {
    int num1, num2, sum;
    printf("Enter two integers: ");
    scanf("%d %d", &num1, &num2);
    sum = num1 + num2;
    printf("Sum: %d\n", sum);
    return 0;
    }
    Copied!

    The scanf function is used to read the input from the user.

    Advanced C Programs

    Check Prime Number

    This program checks whether a given number is a prime number or not.

    Feedback
  2. C Programs - C Programming Examples - GeeksforGeeks

    Dec 27, 2025 · To help you master C programming, we have compiled over 100 C programming examples across various categories, including basic C programs, …

  3. 1000+ C Programs (C Programming Examples) - Includehelp.com

    Apr 1, 2023 · Learn and practice 1000+ C programs with solutions in various categories, library functions, and advanced topics. Find the most important, useful, and latest C programs for beginners …

  4. C programming examples, exercises and solutions for …

    Learn C programming with hundreds of examples, exercises and solutions for beginners. Explore topics such as fundamentals, bitwise operator, ternary …

  5. C Examples - W3Schools

    Well organized and easy to understand Web building tutorials with lots of examples of how to use HTML, CSS, JavaScript, SQL, PHP, Python, Bootstrap, Java and XML.

  6. 100+ C Programs For Practice

    100+ C Programs – Welcome to the ultimate C Programming Practice Hub — a carefully curated collection of 100+ C programs designed to help students …

  7. People also ask
    Loading
    Unable to load answer
  8. C Programming Examples - Tutorial Gateway

    Learn C programming with examples on basic concepts, loops, functions, recursions, and more. Find programs on numbers, conversions, characters, strings, and advanced topics.

  9. C Programming Exercises, Practice, Solution - w3resource

    Mar 20, 2025 · This resource offers a total of 4580 C Programming problems for practice. It includes 916 main exercises, each accompanied by solutions, detailed explanations, and four related problems.

  10. C Programming Examples | C Programs - Sanfoundry

    Learn C programming with many examples of simple and complex programs, from data types to data structures. Each example includes a description, code, and …

  11. Examples of C: Simple C Programs for Beginners (With …

    Oct 30, 2025 · Explore the best examples of C with simple C programs for beginners. Includes basic C programs, practice questions, and solved outputs to …