Add primitive iteration count CLI argument
This commit is contained in:
		
							parent
							
								
									303120f54a
								
							
						
					
					
						commit
						958bbf25b7
					
				| @ -12,9 +12,11 @@ mkPop = population 100 (I prios []) | ||||
| 
 | ||||
| main :: IO () | ||||
| main = do | ||||
|   args <- getArgs | ||||
|   let t = fromMaybe 100 $ headMay args >>= readMaybe | ||||
|   hSetBuffering stdout NoBuffering | ||||
|   pop <- mkPop | ||||
|   pop' <- runEffect $ for (run 2 1 pop (steps 100)) log | ||||
|   pop' <- runEffect $ for (run 2 1 pop (steps t)) log | ||||
|   res <- bests 5 pop' | ||||
|   sequence_ $ format <$> res | ||||
|   where | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user