Click below to go directly to a specific section:
Description | Source Code | Sample Run | Program Notes
This program begins by creating a random vector. This random vector is given the size of 4 and a range for its contents of 0 to 1. This random vector is set equal to a. The while loop counts the number of runs of 0 or 1 and appends its result to a list. The output will be a list of the number of runs in the vector.
This program was tested and executed using Mathematica 3.0