Why don't you stick around for a while and learn about while loops in Java? Sorry. It's been a long day. To make up for it, I'll show you how to write some common algorithms using iteration.
00:00 - Intro
00:13 - Notional Machine
03:05 - while Statement
21:31 - Prime Number Algorithm
28:51 - Identify Digits Algorithm
32:26 - Count Frequency Algorithm
36:34 - Min / Max Algorithm
39:06 - Sum & Average Algorithm