C programme witout using semicolon

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • suresh4ind
    New Member
    • Apr 2007
    • 11

    #1

    C programme witout using semicolon

    Hi

    can we write a C programme without using semicolon,if so how?
    suggest me atleast how the compiler interprets the semicolon as
  • sicarie
    Recognized Expert Specialist
    • Nov 2006
    • 4677

    #2
    Moving this over to the C/C++ Forum (please double-check where you are next time). Thanks

    As I'm sure you've read our Homework Guidelines what do you think? What have you tried?

    Comment

    • ruskalym
      New Member
      • Sep 2007
      • 65

      #3
      Here is a way to make a program with only one semicolon in code :

      Code:
      #include <stdio.h>
      #define NOT_A_SEMICOLON ;
      
      int main()
      {
         printf("No semicolon in this function\n") NOT_A_SEMICOLON
         return 0 NOT_A_SEMICOLON
      }

      Comment

      Working...