MathGroup Archive 2012

[Date Index] [Thread Index] [Author Index]

Search the Archive

while loop through a list

  • To: mathgroup at
  • Subject: [mg128151] while loop through a list
  • From: "tarpanelli at" <tarpanelli at>
  • Date: Wed, 19 Sep 2012 04:57:18 -0400 (EDT)
  • Delivered-to:
  • Delivered-to:
  • Delivered-to:
  • Delivered-to:
  • Reply-to: "tarpanelli at" <tarpanelli at>

i've this problem to solve:

let us suppose I've  a function f which returns a random number and I start 
with an intial list of n random number
I would like to check if each one of the element of this list is below zero 
and if it is applies the function f till when the new random number is above 0. 
This should be repeated for each element of the list such that at the end all 
the list random numbers will be above 0.

Thanks in advance ,

  • Prev by Date: Re: A new FrontEnd
  • Next by Date: Re: set option flag in function definition
  • Previous by thread: Washington DC Area Mathematica SIG
  • Next by thread: Re: while loop through a list