CS 115 - Lab 6

[Back to CS 115 schedule]


Deadlines

Goals

Upon successful completion of this lab, you should be able to understand and write programs using while (indefinite) loops.


Lab Instructions

Follow the links below to complete each part of this lab.

Setup and practice

  1. Basic while loops: the Collatz sequence
  2. Find the largest power of 2 less than a number
  3. Write a number as the sum of powers of 2
  4. Submit your assignment