#include<stdio.h>
#include<conio.h>
void main()
{
int a;
a=10,  // in this line instead of ; i used , 
printf(" The value of a is =%d", a);
getch();
}

In the above program instead of using ; i used , but the compiler is not showing any error and also im getting the correct ouput may i know the reason for that... because any statement should properly end with ;
but how it is working let me know that please
thanks in advance too

Sometimes the comma just acts as a separator instead of an operator. See this wiki article for more details

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.