Board Logo
« Articles on operations in a loop. »

Welcome Guest. Please Login or Register.
Jan 18th, 2018, 3:53pm


Conforums Terms of Service | Membership Rules | Home | Search | Recent Posts | Notification | Format Your Message | Installation FAQ

This board is not meant for general discussion, it is meant for posting articles to help others.
For general discussions use the appropriate board, which best describes your problem area.

« Previous Topic | Next Topic »
Pages: 1  Notify Send Topic Print
 thread  Author  Topic: Articles on operations in a loop.  (Read 1219 times)
tsh73
JB-Supporter


member is offline

Avatar




PM

Gender: Male
Posts: 3636
xx Articles on operations in a loop.
« Thread started on: Jun 7th, 2013, 12:22am »

Single FOR loop, all you can do inside.
You think not much?
But it usually takes whole lection to tell to students!
Here's more or less that lection: Operations in a loop
(If you are experienced user, you may find that you already know all that. But at least you'll have a place to link to in questions like "How am I to calculate sum (average, min/max) in the loop?" (or in an array))

Another article deals with this particular selection
Quote:
...problem:
Imagine you have a choosing program, likely involving big (lengthy) search. You are interested in picking just one of “best” solutions; being “best” amounts to having maximum of some criteria – a single number.
However, beforehand you have no idea what number would it be; more, you have no idea if it would be single solution with maximum criteria or hundreds of them.
But in case you have several of them, you think it would be nice to pick one of them at random – I mean, with equal probability. (In case you program some game ...)

It really takes for granted that you know operations in a loop described in first article.
Single-pass random optimal selection.
User IP Logged

Q: "And if I took your codes and compile them, and sell them for a profit"?
A: Go ahead. I had my share of good then I coded it for fun, if you can make better use of it - please do.
(enjoying JB 1.01 on WinXP, netbook and desktop)
Pages: 1  Notify Send Topic Print
« Previous Topic | Next Topic »

Conforums Terms of Service | Membership Rules | Home | Search | Recent Posts | Notification | Format Your Message | Installation FAQ

Donate $6.99 for 50,000 Ad-Free Pageviews!

| |

This forum powered for FREE by Conforums ©
Sign up for your own Free Message Board today!
Terms of Service | Privacy Policy | Conforums Support | Parental Controls