CSE 114 - HW 2

CSE 114 HW 2 - CSE 114 HW 2 CSE 114 Spring 2010 Computer Science II Home Syllabus Schedule HW 2 Note that this HW assignment is divided into two

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
CSE 114 - HW 2 http://www.cs.sunysb.edu/~cse114/hw/HW2.html[4/13/2010 5:18:08 PM] CSE 114 - Spring 2010 Computer Science II Home Syllabus Schedule HW 2 Note that this HW assignment is divided into two separate parts. You must define a separate program for each part. Work for this HW assignment should be done using the Unix environment. PART 1 - The Password Tester (250 Points) Sparky forces you to change your password every few months to try and prevent others from hacking your account. Keeping the same password on an account for a long period of time makes it more succeptible to hacking. In Unix, you may use the passwd command to change the password on your account. Sparky has conditions on the types of passwords you may select. For example, it requires passwords to be at least 8 characters long and have at least one numeric character. In this part of the assignment, you will define the ProgramTester program, which will test user-entered passwords and determine whether or not they are good password choices, meaning they are fairly secure (hard to hack). After each password test, you will ask the user to either continue and test another password, or quit. This means you will need a loop (iteration) in your program to keep it going. For this assignment, a "good" password must have all of the following characteristics: It must have at least 8 characters, but no more than 16 It must not contain any spaces (Ex: ' ') It must contain at least one upper-case character (Ex: 'A') It must contain at least one lower-case character (Ex: 'a') It must contain at least one digit character (Ex: '4') As we discussed in class, defining methods is an important tool for any programmer in order to make code more reliable and easier to develop and test. As an additional requirement for this assignment, your ProgramTester program, must have at least two methods: your main method, and a method that tests a single password to help the main method. You may add additional helper methods if you like, but only the two are absolutely required. NOTE:
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 04/13/2010 for the course CSE 114 taught by Professor Tashbook during the Spring '08 term at SUNY Stony Brook.

Page1 / 4

CSE 114 HW 2 - CSE 114 HW 2 CSE 114 Spring 2010 Computer Science II Home Syllabus Schedule HW 2 Note that this HW assignment is divided into two

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online