Fomula

 BBS: Inland Empire Archive
Date: 08-14-92 (17:53)             Number: 170
From: LOGAN ASHBY                  Refer#: NONE
  To: STEVE CRAVER                  Recvd: NO  
Subj: Fomula                         Conf: (2) Quik_Bas
13 Aug 92, Steve Craver writes to All:

 SC> D
 SC> Does anyone know the correct formula for finding the MEDIAN of an
 SC> array of numbers? Not the average, just the median.  Thanks Steve


    The numbers must be sorted in ascending order first.
If there are an odd number of values, the median is the
middle value.  If an even number of values, it's the
average of the two middle values.


Logan

--- GoldED 2.40
 * Origin: Big Nerd's Nest  (1:398/1.2)
Outer Court
Echo Basic Postings

Books at Amazon:

Back to BASIC: The History, Corruption, and Future of the Language

Hackers: Heroes of the Computer Revolution (including Tiny BASIC)

Go to: The Story of the Math Majors, Bridge Players, Engineers, Chess Wizards, Scientists and Iconoclasts who were the Hero Programmers of the Software Revolution

The Advent of the Algorithm: The Idea that Rules the World

Moths in the Machine: The Power and Perils of Programming

Mastering Visual Basic .NET