cse-110-lab-8 - CSE 110 Laboratory Assignment 8 This...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
CSE 110 Laboratory Assignment 8 This assignment is due by 11:59 PM on Sunday, November 7. Submit your .java fle through Blackboard — be sure to submit through the link that corresponds to your lab day and time. Lab Description In this week ʼ s lab, you will need to develop your own algorithm For a short Java program. This program requires you to use loops and if statements. Start by thinking careFully about the problem that is described below. You may fnd it helpFul to start by writing some pseudocode or drawing a simple ±owchart on a piece oF paper beFore you start to write any code. You may also fnd it helpFul to work incrementally: write some code to perForm one (simple) task, then expand it to perForm a second task, and so on, testing as you go. A positive integer is called a perfect number iF it is equal to the sum oF all oF its positive divisors, excluding itself . ²or example, 6 is the frst perFect number because 6 = 3 + 2 + 1. The second perFect number is 28 = 14 + 7 + 4 + 2 + 1. Write a small Java program From scratch that reads in a positive integer
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 12/06/2011 for the course CSE 110 taught by Professor Shaunakpawagi during the Fall '08 term at SUNY Stony Brook.

Ask a homework question - tutors are online