potter
Member
Registered: Feb 2000
Location: SW Virginia
Posts: 290 |
C code play
Using the basic [CODE] tag: code: #include <stdio.h>
#include "localHeader.h"
int main(
int argc,
char **argv )
{
int iVar = 1;
double dVar = 2.3;
char cVar = 'x';
char *str = "This is a string";
printf( "Testing 1, 2, 3\n" );
if ( iVar ) {
do {
dVar -= 0.1;
} while ( dVar > 0.0 );
} else {
printf( "foo\n" );
}
return 1;
}
Now using the [PHP] tag:PHP:
#include <stdio.h>
#include "localHeader.h"
int main(
int argc,
char **argv )
{
int iVar = 1;
double dVar = 2.3;
char cVar = 'x';
char *str = "This is a string";
printf( "Testing 1, 2, 3\n" );
if ( iVar ) {
do {
dVar -= 0.1;
} while ( dVar > 0.0 );
} else {
printf( "foo\n" );
}
return 1;
}
Hmm, if it did not put the PHP: in befor the code block, this would be very usable for C code.
|