2013-05-06 11:34:32 -04:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								USING: help.markup help.syntax math ;
							 | 
						
					
						
							
								
									
										
										
										
											2013-05-04 20:08:48 -04:00
										 
									 
								 
							 | 
							
								
							 | 
							
								
							 | 
							
							
								IN: math.combinators
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								HELP: when-negative
							 | 
						
					
						
							
								
									
										
										
										
											2013-05-07 11:18:20 -04:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								{ $values { "n" real } { "quot" "the first quotation of an " { $link if-negative } } }
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								{ $description "When " { $snippet "n" } " is negative, calls the quotation with " { $snippet "n" } "." }
							 | 
						
					
						
							
								
									
										
										
										
											2013-05-06 11:34:32 -04:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								{ $examples
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								    { $example "USING: math math.combinators prettyprint ;" "-3 [ 1 + ] when-negative ." "-2" }
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								    { $example "USING: math math.combinators prettyprint ;" "3.5 [ 1 + ] when-negative ." "3.5" }
							 | 
						
					
						
							
								
									
										
										
										
											2013-05-04 20:08:48 -04:00
										 
									 
								 
							 | 
							
								
							 | 
							
								
							 | 
							
							
								} ;
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								HELP: when-positive
							 | 
						
					
						
							
								
									
										
										
										
											2013-05-07 11:18:20 -04:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								{ $values { "n" real } { "quot" "the first quotation of an " { $link if-positive } } }
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								{ $description "When " { $snippet "n" } " is positive, calls the quotation with " { $snippet "n" } "." }
							 | 
						
					
						
							
								
									
										
										
										
											2013-05-06 11:34:32 -04:00
										 
									 
								 
							 | 
							
								
									
										
									
								
							 | 
							
								
							 | 
							
							
								{ $examples
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								    { $example "USING: math math.combinators prettyprint ;" "1.5 [ 1 + ] when-positive ." "2.5" }
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								    { $example "USING: math math.combinators prettyprint ;" "-1 [ 1 + ] when-positive ." "-1" }
							 | 
						
					
						
							| 
								
							 | 
							
								
							 | 
							
								
							 | 
							
							
								} ;
							 |