Computers and Technology

You are an analyst at the Central Intelligence Agency (CIA). You are assigned the job of developing a program that will analyze PIN numbers that are used to encrypt sensitive data. The CIA uses a very specific set of rules for PINs to identify non-CIA operatives who attempt to access the sensitive data (these non-CIA operatives will try PINs that do not conform to CIA rules). The rules are complicated enough that the CIA has assigned you the job of developing a program to test whether a PIN meets their rules. CIA personnel will then use the program to make sure the PINs they select to protect data conform to the rules.

The rules that your program must use to determine if the password is valid are as follows:

1. The password must be an integer greater than or equal to 100,000 and less than 1,000,000
2. All the digits in the number have to be unique.
3. The sum of the digits must be a prime number.
4. The permutation of the left - most digit (n) and the smallest digit (k) must be odd - for example: in 645923, the left - most is 6 and the smallest digit is 2.

n! / (n - k)!
Where the ! denotes a factorial. For example, for the number 645923, the permutation with n = 6 and k = 2 is: 6 * 5 * 4 * 3 * 2 * 1 / (4 * 3 * 2 * 1) = 30. You will list all valid passwords. In addition, you will need to list the total number of valid passwords at the end.

answer
Answers: 2

Other questions on the subject: Computers and Technology

image
Computers and Technology, 22.06.2019 14:30, qxchung7310
The β€œrule of 72” is used to approximate the time required for prices to double due to inflation. if the inflation rate is r%, then the rule of 72 estimates that prices will double in 72/r years. for instance, at an inflation rate of 6%, prices double in about 72/6 or 12 years. write a program to test the accuracy of this rule. for each interest rate from 1% to 20%, the program should display the rounded value of 72/r and the actual number of years required for prices to double at an r% inflation rate. (assume prices increase at the end of each year.)
Answers: 1
image
Computers and Technology, 22.06.2019 23:30, keviongardner
The next button in the review section shows the next available comment. next slide with no comment. previous comment. edited comment.
Answers: 1
image
Computers and Technology, 23.06.2019 16:30, azainababbas
20 points archie wants to use a reflector as he photographs a newlywed couple. what would he consider in his choice? a. shadow and sunny b. homemade and professional c. lamps and boards d. incident and reflected e. neutral density and enhancement
Answers: 3
image
Computers and Technology, 23.06.2019 20:00, boo3972
Match the file formats with the types of multimedia they can store
Answers: 2
Do you know the correct answer?
You are an analyst at the Central Intelligence Agency (CIA). You are assigned the job of developing...

Questions in other subjects:

Konu
Mathematics, 31.10.2019 04:31
Konu
Mathematics, 31.10.2019 04:31
Konu
Mathematics, 31.10.2019 04:31