PLEX86  x86- Virtual Machine (VM) Program
 Plex86  |  CVS  |  Mailing List  |  Download  |  Computer Folklore     

CSE 143 and professor Kelsey both give me points off for using Loop. 14059


VPN Service Provider

Hi Spooky ( and professor Kelsey ), Re: Me getting points off for using Loop() in CSE 143,

Because they, like professor Kelsey and you, can't recognize fine code when they see it, no doubt.

int main() { int x = 3, y = 4; if ( min( x, y ) == x ) puts( "X is less" ); if ( min( x++, y++ ) == y ) puts( "y++ is less" );

int main( int argc, char ** argv ) { FILE * fp = fopen("XY.TXT","w"); if ( argc != 3 ) { fprintf( fp, "Example syntax: XY.EXE 3 4n"); fclose( fp ); return -1 ; } int X = atoi ( * ++ argv ), Y = atoi ( * ++ argv ); if ( er( X, Y ) == X ) fprintf( fp, " X is smaller.-n" ); if ( er( X ++, Y ++ ) == Y - 1 ) fprintf( fp, " Y is smaller.-n" ); if ( er( -- X, -- Y ) == X ) fprintf( fp, " X is still smaller.-n" );

You not only switched an arrow for a peashooter but completely missed the apple ( not to mention the tree, the person under the apple, The point is plain to see, never use min(), use Smaller() and BiggER() instead.

main() { int x = rand(); externfunc( x );

Probability is admittedly 1 in about 32,768.

Unfortunately I'm not sure how to elegantly demonstrate the return of a random value in AX on a COMMAND.EXE shell, though one can try to code up something in VBScript or just plain old .BAT, using IF.

Microsoft wants C++ to replace C, which is fine with me
Hi Spooky ( and Arkady Duntov ), Re: Why I use MSC++ instead of MSC, I think Microsoft wants C++ to...

Or one might invoke CreateProcess() on the test program and see what the process returns.

WinXP has no rule saying an .EXE file must return something.

Microsoft wants C++ to replace C, which is fine with me. 14062
In comp.os.linux.advocacy, JeffRelf wrote on 12 Apr 2005 03:13:11 GMT C is a language. MSC...

I know, WinXP is case insensitive like that... Gotta love it !


Linux | Previous | Next

Microsoft wants C++ to replace C, which is fine with me

Linux Advocacy Newsgroups

CSE 143 and professor Kelsey both give me points off for using Loop. 14058