A web about organizing the first Transhackmeeting in Pula
View   r1
CleaninG 1 - 06 Oct 2008 - Main.TWikiGuest
Line: 1 to 1
Added:
>
>
META TOPICPARENT name="WebHome"
dish washing made easy (by strafwetboek( )causaencantada.org)

If we call this function (where MAX_containers is the maximum number of containers full of water, ordered by its decreasing level of soap so the last one have no soap inverselly the first one) for each instance of THacKer exactly after the end of its own nutrition process, each THacKer will end this process with a clean dishes set, ready to share with the next hungry THacKer, even in the same nutrition session or another one after that. (MAX_containers is defined by Monteparadiso ppl, dirt_level by THacKer)

void wash_your_own_dishes_THK_U(MAX_containers, dirt_level)
{																									 
  int container;  
  printf("Who is the last one?\n");	 
  for(container=1; container<=MAX_containers; container++)  
  {								  
	 insert(dishes);																																				  
	 wash(dishes);																																					 
	 remove(dishes);																																				  
	 dirt_level--;																																					 
  }																																										
  share(dishes);																																					  
  printf("Where is the next workshop?\n");																													
}																																										  

This is a serial process wich can be improved in many ways. Setting two rows can paralelize it, but I think duplicating the first full-soap container can improve it without costs looses, because the time need to initially understand the process.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

-- DarkVeggy? - 17 Jun 2004


Revision 1r1 - 06 Oct 2008 - 12:26:38 - TWikiGuest
This site is powered by the TWiki collaboration platformCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback
Syndicate this site RSSATOM