Changes in src/tests/datingService.c [6c7b1e7:2ba0bc7]
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/tests/datingService.c
r6c7b1e7 r2ba0bc7 9 9 // Created On : Mon Oct 30 12:56:20 2017 10 10 // Last Modified By : Peter A. Buhr 11 // Last Modified On : Mon Oct 30 23:02:11 201712 // Update Count : 1 511 // Last Modified On : Mon Oct 30 17:58:41 2017 12 // Update Count : 14 13 13 // 14 14 15 #include <stdlib> // rand om15 #include <stdlib> // rand48 16 16 #include <fstream> 17 17 #include <kernel> … … 61 61 62 62 void main( Girl & g ) { 63 yield( rand om( 100 ) ); // don't all start at the same time63 yield( rand48( 100 ) ); // don't all start at the same time 64 64 unsigned int partner = girl( g.TheExchange, g.id, g.ccode ); 65 65 //sout | "Girl:" | g.id | "is dating Boy at" | partner | "with ccode" | g.ccode | endl; … … 79 79 80 80 void main( Boy & b ) { 81 yield( rand om( 100 ) ); // don't all start at the same time81 yield( rand48( 100 ) ); // don't all start at the same time 82 82 unsigned int partner = boy( b.TheExchange, b.id, b.ccode ); 83 83 //sout | " Boy:" | b.id | "is dating Girl" | partner | "with ccode" | b.ccode | endl; … … 96 96 Boy *boys[NoOfPairs]; 97 97 98 rand om_seed( getpid() );98 rand48seed( getpid() ); 99 99 100 100 for ( unsigned int i = 0; i < NoOfPairs; i += 1 ) {
Note: See TracChangeset
for help on using the changeset viewer.