Question 1 (3 pts) Taking the following rules into consideration:
• An integer, greater than 1, that is only divisible by 1 and itself is called a prime number.
• A composite number is a whole number with more than two integer divisors.
• All non-prime numbers greater than 1 are called composite numbers.
• The integers 0 and 1 are neither prime nor composite. • A number cannot be both prime and composite. Write a program that asks the user to input a positive integer. The program should:
1- Check if the value entered is represents a number. If not, the user is prompted to re-enter a valid number (the program should not exit).
2- Inform the user if the number is a prime number, a composite number or neither prime nor composite (the program should not exit).
3- Loop continuously asking the user if they wish to continue (yes/no). If no is entered, the program exits. Hints:
• You need to use a loop. That is, you cannot import a library that has the prime function implemented and use it.
• Only usage of string.isnumeric(), string.isalnum(), string.isdigit() functions is permitted (see instructions page).
• If you use any other approach besides looping, no credit will be given. Sample Interaction: Please enter a positive integer: hello This is not a valid positive integer value. Please re-enter a valid positive integer: -5 This is not a valid positive integer value. Please re-enter a valid positive integer:
5 The number you entered is a prime number. It is not a composite number. Would you like to continue? (yes/no): yes Please enter a positive integer:
6 The number you entered is not a prime number. It is a composite number. Would you like to continue? (yes/no): yes Please enter a positive integer: -
1 This is not a valid positive integer value. Please re-enter a valid positive integer:
2 The number you entered is a prime number. It is not a composite number. Would you like to continue? (yes/no): yes Please enter a positive integer: 199 The number you entered is a prime number. It is not a composite number. Would you like to continue? (yes/no): yes
CS 340 Milestone One Guidelines and Rubric Overview: For this assignment, you will implement the fundamental operations of create, read, update,
Retail Transaction Programming Project Project Requirements: Develop a program to emulate a purchase transaction at a retail store. This
7COM1028 Secure Systems Programming Referral Coursework: Secure
Create a GUI program that:Accepts the following from a user:Item NameItem QuantityItem PriceAllows the user to create a file to store the sales receip
CS 340 Final Project Guidelines and Rubric Overview The final project will encompass developing a web service using a software stack and impleme