Description
Unformatted Attachment Preview
CSC 122 – INTRODUCTION TO PROGRAMMING
PROG #5
100 POINTS
Programming Exercise #5
Count and Sum of Numbers
Due: April 6, 2015
Instructions: Write a program that reads all of the numbers stored in a file called
“numbers.txt” that was created by your instructor and then display the following:
1. A count of the numbers read from the file.
2. A count of the even numbers read from the file.
3. A count of the odd numbers read from the file.
4. The sum of the even numbers read from the file.
5. The sum of the odd numbers read from the file.
NOTE: A number is even is it can be divided by 2 and has no remainder.
Explore the ideal of using the % (remainder) symbol to accomplish this.
See Chapter 2, page 54 for more information.
Programming Style Requirements
1. Standard Output Program Header Information
CSC 122-W1 – Program #5
By
The standard output program header information is to be included at the top of
the program and should be the first lines displayed on the output screen.
2. Comments
The program must include a main comment block (2-3 lines is sufficient) before
the standard output program header information that describes the purpose of
the program. There should also be comments included throughout the program
to describe what is going on in the program (i.e. input and calculation).
3. Descriptive names must be used for all variables in the program.
4. The program must have at least one (1) function.
5. The program must properly label the output. See the screen capture below.
Winter 2015
1
4/6/2015
CSC 122 – INTRODUCTION TO PROGRAMMING
PROG #5
6. Saving the Program
Save the source code for the program as Prog5.py
Required Output:
The program output should look identical to the screen capture above.
NOTE: When testing your program, make sure the numbers.txt file is located in the
same area that your source code is located. If the text file cannot be found when the
program is executed, the following error message will be displayed:
Winter 2015
2
4/6/2015
CSC 122 – INTRODUCTION TO PROGRAMMING
PROG #5
When the program is working correctly and free of syntax errors, submit the Prog5.py
file to Blackboard. (DO NOT send the program via email. Only homework
submitted via Blackboard will be graded.)
Grade Rubric:
Points
Description
5
The program is saved as Prog5.py.
5
The program displays the standard program header information.
10
A main comment block is included to describe what the program does.
See #2 above.
5
Comments are included throughout the program to describe the difference
processes used. See #2 above.
10
Descriptive variable names are used in the program.
10
The program contains at least one (1) function.
10
The program displays a count of the numbers read from the file.
10
The program displays a count of the even numbers read from the file.
10
The program displays a count of the odd numbers read from the file
10
The program displays the sum of the even numbers read from the file.
10
The program displays the sum of the odd numbers read from the file.
5
The program output is identical to the required output. See screen capture
above.
100
Total Points
Program should be submitted by Monday, April 6.
Winter 2015
3
4/6/2015
Purchase answer to see full attachment
Purchase answer to see full attachment
User generated content is uploaded by users for the purposes of learning and should be used following Studypool's honor code & terms of service.
Explanation & Answer
Review
Review
Anonymous
I was having a hard time with this subject, and this was a great help.
Studypool
4.7
Trustpilot
4.5
Sitejabber
4.4
24/7 Homework Help
Stuck on a homework question? Our verified tutors can answer all questions, from basic math to advanced rocket science!
Most Popular Content
5 pages
Prostate Cancer Case Study.
A prostate tumor is the improvement of growth in the prostate, which is an organ found in the male regenerative framework. ...
Prostate Cancer Case Study.
A prostate tumor is the improvement of growth in the prostate, which is an organ found in the male regenerative framework. Most prostate develop ...
create subject class,number of classes,display using GUI, investigate on various programming, computer science homework help
Task 1 is to create subject class and test its properties, Task 2 is to create a number of classes and then test their pr ...
create subject class,number of classes,display using GUI, investigate on various programming, computer science homework help
Task 1 is to create subject class and test its properties, Task 2 is to create a number of classes and then test their properties, Task 3 is to display a frame using GUI, and Task 4 is to investigate on various programming paradigm.Task 1Value: 8 marksFor this task you will create a Subject class, whose instances will represent the subjects for study at a university. A subject will have a name, just a String (for example, Programming in java 1), and a subject code (for example, ITC206), which is a six-character String. The first three characters of a subject code are alphabetic and the last three are numeric. The first three characters define the subject's discipline area. A subject code must be unique.You will also write a TestSubject class to test the use of your Subject class. In particular this will maintain an array of subjects. In order to manage the uniqueness of the subject codes, your program will need to display information about existing subject codes as well as checking that any new subject code supplied by the user is not the same as any existing subject code.The following state and functionality should be provided for the Subject class:Two fields will hold the subject’s name and the six-character subject code.A constructor will allow a name and a new, validated subject code to be provided when a new subject is created.Getters will provide access to the attributes i.e. subject name and subject code.An accessor method called getDiscipline will return a string containing the first three characters of the subject code (for example ITC from ITC206 subject code).Another accessor method called codeMatches will return a boolean value indicating if the subject's code matches the string argument provided. "Matches" is used here in the same sense as for the matches method of the String class.A toString method will return a string containing the subject code and subject name.To assist with managing subject codes and their uniqueness you will provide the Subject class with some class methods as follows:An allDisciplines method will accept an array of Subject objects. It will return an array containing the different 3-character discipline codes represented in the array of subjects in alphabetically order. A codesPerDiscipline method will accept an array of Subject objects and a 3-character discipline code. It will return an array containing the different subject codes represented in the array of subjects for the particular discipline.An isValidCode method will accept a string that is a possible new subject code, and return a boolean indicating whether it satisfies the structural requirements for a subject code.A codeExists method will accept an array of Subject objects and a possible new subject code. It will return a boolean indicating whether that code has already been allocated to one of the subjects in the array.A sortDisciplines method will accept an array of Subjects objects. It will return the sorted array of subjects in alphabetically order (you may sort based on the subject code only). Your TestSubject program will perform the following sequence of actions, using good design techniques such as in the appropriate use of methods:An initial array of Subject objects will be created from any data in a file that was previously saved by the program. Then you need to read Subject objects from the file and store in appropriate array using your java program.The user interaction will then proceed to allow the user to add one or more new subjects to the array. If the user wishes to add new subjects, the discipline areas of existing subjects should be displayed in alphabetically order. The user will then enter a discipline code to which the program will respond by displaying any existing subject codes in that discipline. This procedure simplifies the user’s task of choosing subject codes that do not already exist, but does not prevent user mistake. Each subject code entered by the user should be checked. The user can enter any new subjects in that discipline (or indeed in other disciplines). The user should be given the choice of repeating the processing for other discipline areas.When the user has finished adding subjects, and only if subjects have indeed been added, the program will overwrite the data file with the updated data.Note:You may use an ArrayList to implement an array if you prefer and it is appropriate.Task 2Value: 5 marks(a) Define an abstract class called Textbook with the following fields and methods: ·Fields: title, author, pages representing the title, author and the number of pages of a textbook for a given book respectively. Encapsulation should be used to protect these fields against intentional or accidental, direct modification·Constructors: a no-args default constructor, and an overloaded constructor to initialise the fields to appropriate values when the instances of the class are created·Methods: a toString() method to print a string representation of the objects, get and set methods to provide access to each of the three fields(b) Define a subclass of the Textbook class called ProgrammingTextbook with the following additional field and methods: ·Field: language representing the particular language the programming textbook uses. Again, encapsulation should be used to protect this field against intentional or accidental, direct modification·Constructors: a no-args default constructor, and an overloaded constructor to initialise the fields to appropriate values when the instances of the class are created·Methods: a toString() method to print a string representation of the objects, additional get and set methods as required to provide access to the field(c) Define another subclass of the Textbook class called EngineeringTextbook with the following additional field and methods:·Field: subject representing the particular engineering subject the textbook teaches. Again, encapsulation should be used to protect this field against intentional or accidental, direct modification·Constructors: a no-args default constructor, and an overloaded constructor to initialise the fields to appropriate values when the instances of the class are created·Methods: a toString() method to print a string representation of the objects, additional get and set methods as required to provide access to the field(d) Finally, define another class called TestTextbooks with a main() method to perform necessary testing for the classes defined in the previous sections. In the main method, write the code to create at least two objects of the ProgrammingTextbook class and at least two other objects of the EngineeringTextbook class. Create an ArrayList object to store references to these objects and then test various methods of the objects using loop(s) and methods as necessary. Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.Task 3Value: 4 marksWrite a Java program using JavaFX that displays five playing cards. In the first row display three playing cards (randomly selected from the first 52 cards). In the second and third rows display a Joker card at 45 degree and 90 degree angles respectively. The image icons used in the questions are available in the Resource folder of Interact2. You may need to use HBox and/or VBox Pane. Task 4Value: 3 marksInvestigate the imperative programming paradigm, as exemplified by procedural programming and object-oriented programming, and the declarative programming paradigm, as exemplified by functional programming and logic programming.The Reading from Brookshear, 2012 will form a starting point for your investigation. For further investigation, remember that you should not reference Wikipedia items in an essay, so make sure to find articles that you can reference.Write an essay, of approximately 800 words, based on your investigation, which provides answers to the following questions:What are the essential differences between the paradigms?What are some of the programming languages used for these different paradigms?What specific advantages are provided by these different programming approaches?Your essay should be referenced using the APA referencing style.Rationaleto interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (objective 2);to apply inheritance and aggregation patterns in the design and implementation of programs (Objective 3);be able to compare and critically evaluate different programming paradigms (Objective 6);to manipulate file operations through Java programming; (objective 7);to use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (objective 4);to implement Graphical User Interface) (GUI )components using Java (objective 8).Marking criteriaThese criteria will be used to evaluate Assignment 3:The tasks are performed as specified and the assignment is submitted as requiredAppropriate understanding of the subject area is demonstrated, including correct use of approriate techniquesExplanations and discussions are cogent and use clear and correct English expressionReferencing is used where appropriatePresentationMaterial to submit for Task 11.You need to submit the java and class files2.You also need to submit a doc/pdf file with following information:a.Analysis: Describe the problem including input and output in your own words (not more than 400 words)b.Testing: Describe how you test this program (not more than 400 words)c. Output: Copy and paste a snapshot of the program outputMaterial to submit for Task 21.You need to submit the java and class files2.You also need to submit a doc/pdf file with following information:a.Analysis: Describe the problem including input and output in your own words (not more than 400 words)b.Testing: Describe how you test this program (not more than 400 words)c. Output: Copy and paste a snapshot of the program outputMaterial to submit for Task 31. You need to submit the java and class files2. You also need to submit a doc/pdf file with following information:a. Analysis: Describe the problem including input and output in your own words (not more than 400 words)b. Testing: Describe how you test this program (not more than 400 words)c. Output: Copy and paste a snapshot of the program output Material to submit for Task 41. You need to submit a doc/pdf file which includes the easy.RequirementsTo complete this assignment you might need to have covered material up to and including the topic Inheritance and Polymorphism, abstract classes and interfaces, Thinking of Objects, GUI basics, and UML in the Text Book and module.
Arizona State University Python File Script Coding Sample Run
InstructionsFor each part of the lab; create a python file with the name; part#-ASURITE.pywhere # is the part of the labAS ...
Arizona State University Python File Script Coding Sample Run
InstructionsFor each part of the lab; create a python file with the name; part#-ASURITE.pywhere # is the part of the labASURITE is your user nameExample: part1-cjingers.py, part2-cjingers.pySubmit all .py files as part of your submissionDon't forget the interpreter line!The output of your script must match the same format shown in the sample run for each part.Part 1 Write a Python script that will prompt the user for monetary value (such as 11.26). Then, calculate the number of dollars, quarters, dimes, nickels, and pennies. Your solution should use the maximum possible number of dollars, then quarters and so on. For example; converting 11.26 to 1126 pennies is not acceptable.Sample runEnter an ammount of money: 11.56Your amount of $11.56 consists of; 11 dollars 2 quarters 0 dimes 1 nickels 1 penniesPart 2Given two points, the formula for computing distance is;(x2−x1)2+(y2−y1)2−−−−−−−−−−−−−−−−−−√(x2−x1)2+(y2−y1)2Write a Python script that prompts the user for two points and computes the distance between them.A point is comprised of two floating point numbers; representing the x and y coordinates.Sample runEnter x1 and y1 for Point 1: 1.5, -3.4Enter x2 and y2 for Point 2: 4, 5The distance between (1.5, -3.4) and (4, 5) is 8.8
NVCC Programming Codes Mistake Loops & Step Value Questions Discussion
Answer questions in the order provided and in detail (NOT Summary answer) What is an advantage of using fewer instruc ...
NVCC Programming Codes Mistake Loops & Step Value Questions Discussion
Answer questions in the order provided and in detail (NOT Summary answer) What is an advantage of using fewer instructions?What are the three steps that should occur in every loop?What is the difference between a definite loop and an indefinite loop?Explain when it would be appropriate to write an indefinite loop.What are common mistakes made by programmers in coding loops?What is a step value?When are you required to use a for statement, and what are the advantages of for statements?What is an accumulator?
Please complete Honors Programming Assignment- Programming Assignment 2
Please complete Honors Programming Assignment- Programming Assignment 2The tutor should be familiar with Terminal or Pytho ...
Please complete Honors Programming Assignment- Programming Assignment 2
Please complete Honors Programming Assignment- Programming Assignment 2The tutor should be familiar with Terminal or PythonI already attached (Assignment_2.tar.gz) file for you You can also download (Assignment_2.tar.gz) file from the following linksAssignment_2.tar.gzhttps://d3c33hcgiwev3.cloudfront.net/_e20ed72f0f03...please find the attached files for more details .Thanks
CMPEN 472 Pennsylvania University Arithmetic Instructions and Basic System Worksheet
Due: March 8, 2021 11:30pm
Objective
To learn how to use arithmetic instructions and write basic s ...
CMPEN 472 Pennsylvania University Arithmetic Instructions and Basic System Worksheet
Due: March 8, 2021 11:30pm
Objective
To learn how to use arithmetic instructions and write basic system I/O subroutines. Learn user interface through a serial port.
Instruction
Write a user-friendly system program for the following commands:
S: Show the contents of memory location
W: Write the data byte to memory location
QUIT: Quit the main program, run 'Type writer' program.
Command S: This command shows the contents of memory location specified by the address in hexadecimal number followed by the 'S' character. For example, if the data $6A is stored in memory location $3000, a user types in the first line ending with Enter/Return key and the following should be displayed on the HyperTerminal connected to the HCS12 board:
>S$3000
$3000 = $6A 106
>
The data $6A is printed in both hexadecimal and decimal number format. The character '>' is the prompt for this program.
Command W: this command writes data into the memory location specified by the address in hexadecimal followed by the 'W' character. The data to be written to the memory location is followed by a space and it can be specified by hexadecimal '$' or just decimal number. For example, if one wants to store the data $6A in memory location $3001, a user types in the first line ending with Enter/Return key and the following should be displayed on the HyperTerminal connected to the HCS12 board:
>W$3001 106
$3001 = $6A 106
>
Or
>W$3001 $6A
$3001 = $6A 106
>
As a result, the data $6A is stored in the memory location $3001 and it is shown with the 'S' command. The 'W' command accepts both '106' or '$6A' as an 8 bit number.
For HCS12 chip, assume memory address is a 16 bit number and each memory location hold an 8 bit data.
Design the program to start at $3100 and data to start at $3000.
Make your program user-friendly and fool proofed. Print detail guide on the terminal screen so that users will properly use your program. Once your program is running, everything must be self-explanatory to user at the Hyper Terminal.
For this homework, you must do error checking to see if correct input is entered by a user. And give correct command usage example if invalid command was entered. Your program must NOT crash or hang if a user enters wrong input.
The HyperTerminal display should look something like the following:go 3100 Welcome to the Simple Memory Access Program! Enter one of the following commands (examples shown below) and hit 'Enter'. >S$3000 ;to see the memory content at $3000 > $3000 = $6A 106 > >W$3001 $6A ;to write $6A to memory location $3001 > $3000 = $6A 106 > >W$3001 106 ;to write $6A to memory location $3001 > $3000 = $6A 106 > QUIT ;to the Simple Memory Access Program Type writing now: >S$30G0 > invalid input, address > >S$30123 > invalid input, address > >S345678 > invalid input, address > >W$3001 $6AB > invalid input, data > >W$3001 300 > invalid input, data > >W$3001 > invalid input, data > >W$3001 -106 > invalid input, data > >W$3 $0F > $0003 = $0F 15 > >W$300 $9 > $0300 = $09 9 > >W$4000 12 > $4000 = $0C 12 > >W$0001 005 > $0001 = $05 5 >
You may want to first draw the Flow Chart of the above algorithm.
Be sure to put much comments so that grader and others can clearly and quickly understand your program. Comments are very important in assembly language programs.
You may want to see and check the Sample Grading Sheet for this homework.
Copy your 'main.asm' file to 'cmpen472hw6_YourLastName.asm'. For example, mine will be 'cmpen472hw6_choi.asm' Then turn-in your .asm file (do NOT ZIP your file).
Turn-in your project source code file through Penn State CANVAS. Upload your source code file into the CANVAS Assignment's Homework submission. Be sure to select CMPEN 472 class and correct Homework number, and with correct file name.
Congratulations on your sixth CMPEN 472 homework completion!
Here is a link for the codewarrior idle install https://drive.google.com/file/d/19HVtjjhX8aJEh2oDa...
Similar Content
CSD 101 Methodist University Make Up Generator Personal Web Page
Need help in creating a Personal web page for my daughter, she is in High School in the 9th Grade, and I have no Ide...
database mysql
please answer the four questions in documents below >>>>>>>>>>>...
Anadroid Programming
Android IT preview . i just need 1 paragraph...
Explain what is meant by value type and reference type objects in C#
Explain what is meant by value type and reference type objects in C#. Explain the differences, providing an example of eac...
SWE 440 CTU Online Waterfall Software Development Methodology Research Paper
Using the financial management software initiative and the project plan that you created in Unit 1 as a base, develop a re...
computer hard ware, programming homework help
Make a one page graphic guide for the Motherboard and CPU that you can use in troubleshooting ?...
Postfiexpressionjava
* default constructor (assigns an empty String to the String instance variable * and a new ArrayList to the instance Array...
Java Problem 1 Programming
Sample output with “Hi there “ - as the user input....
Student Registration System 1.12
This is a student registration system that helps to capture the students details in using a form and later submits the...
Related Tags
Book Guides
The King Must Die
by Mary Renault
Dune
by Frank Herbert
To Kill a Mockingbird
by Harper Lee
No Exit
by Taylor Adams
The Picture of Dorian Gray
by Oscar Wilde
Cant Hurt Me - Master Your Mind and Defy the Odds
by David Goggins
Dracula
by Bram Stoker
Ezperanza Rising
by Pam Muñoz Ryan
The Great Gatsby
by Francis Scott Key Fitzgerald
Get 24/7
Homework help
Our tutors provide high quality explanations & answers.
Post question
Most Popular Content
5 pages
Prostate Cancer Case Study.
A prostate tumor is the improvement of growth in the prostate, which is an organ found in the male regenerative framework. ...
Prostate Cancer Case Study.
A prostate tumor is the improvement of growth in the prostate, which is an organ found in the male regenerative framework. Most prostate develop ...
create subject class,number of classes,display using GUI, investigate on various programming, computer science homework help
Task 1 is to create subject class and test its properties, Task 2 is to create a number of classes and then test their pr ...
create subject class,number of classes,display using GUI, investigate on various programming, computer science homework help
Task 1 is to create subject class and test its properties, Task 2 is to create a number of classes and then test their properties, Task 3 is to display a frame using GUI, and Task 4 is to investigate on various programming paradigm.Task 1Value: 8 marksFor this task you will create a Subject class, whose instances will represent the subjects for study at a university. A subject will have a name, just a String (for example, Programming in java 1), and a subject code (for example, ITC206), which is a six-character String. The first three characters of a subject code are alphabetic and the last three are numeric. The first three characters define the subject's discipline area. A subject code must be unique.You will also write a TestSubject class to test the use of your Subject class. In particular this will maintain an array of subjects. In order to manage the uniqueness of the subject codes, your program will need to display information about existing subject codes as well as checking that any new subject code supplied by the user is not the same as any existing subject code.The following state and functionality should be provided for the Subject class:Two fields will hold the subject’s name and the six-character subject code.A constructor will allow a name and a new, validated subject code to be provided when a new subject is created.Getters will provide access to the attributes i.e. subject name and subject code.An accessor method called getDiscipline will return a string containing the first three characters of the subject code (for example ITC from ITC206 subject code).Another accessor method called codeMatches will return a boolean value indicating if the subject's code matches the string argument provided. "Matches" is used here in the same sense as for the matches method of the String class.A toString method will return a string containing the subject code and subject name.To assist with managing subject codes and their uniqueness you will provide the Subject class with some class methods as follows:An allDisciplines method will accept an array of Subject objects. It will return an array containing the different 3-character discipline codes represented in the array of subjects in alphabetically order. A codesPerDiscipline method will accept an array of Subject objects and a 3-character discipline code. It will return an array containing the different subject codes represented in the array of subjects for the particular discipline.An isValidCode method will accept a string that is a possible new subject code, and return a boolean indicating whether it satisfies the structural requirements for a subject code.A codeExists method will accept an array of Subject objects and a possible new subject code. It will return a boolean indicating whether that code has already been allocated to one of the subjects in the array.A sortDisciplines method will accept an array of Subjects objects. It will return the sorted array of subjects in alphabetically order (you may sort based on the subject code only). Your TestSubject program will perform the following sequence of actions, using good design techniques such as in the appropriate use of methods:An initial array of Subject objects will be created from any data in a file that was previously saved by the program. Then you need to read Subject objects from the file and store in appropriate array using your java program.The user interaction will then proceed to allow the user to add one or more new subjects to the array. If the user wishes to add new subjects, the discipline areas of existing subjects should be displayed in alphabetically order. The user will then enter a discipline code to which the program will respond by displaying any existing subject codes in that discipline. This procedure simplifies the user’s task of choosing subject codes that do not already exist, but does not prevent user mistake. Each subject code entered by the user should be checked. The user can enter any new subjects in that discipline (or indeed in other disciplines). The user should be given the choice of repeating the processing for other discipline areas.When the user has finished adding subjects, and only if subjects have indeed been added, the program will overwrite the data file with the updated data.Note:You may use an ArrayList to implement an array if you prefer and it is appropriate.Task 2Value: 5 marks(a) Define an abstract class called Textbook with the following fields and methods: ·Fields: title, author, pages representing the title, author and the number of pages of a textbook for a given book respectively. Encapsulation should be used to protect these fields against intentional or accidental, direct modification·Constructors: a no-args default constructor, and an overloaded constructor to initialise the fields to appropriate values when the instances of the class are created·Methods: a toString() method to print a string representation of the objects, get and set methods to provide access to each of the three fields(b) Define a subclass of the Textbook class called ProgrammingTextbook with the following additional field and methods: ·Field: language representing the particular language the programming textbook uses. Again, encapsulation should be used to protect this field against intentional or accidental, direct modification·Constructors: a no-args default constructor, and an overloaded constructor to initialise the fields to appropriate values when the instances of the class are created·Methods: a toString() method to print a string representation of the objects, additional get and set methods as required to provide access to the field(c) Define another subclass of the Textbook class called EngineeringTextbook with the following additional field and methods:·Field: subject representing the particular engineering subject the textbook teaches. Again, encapsulation should be used to protect this field against intentional or accidental, direct modification·Constructors: a no-args default constructor, and an overloaded constructor to initialise the fields to appropriate values when the instances of the class are created·Methods: a toString() method to print a string representation of the objects, additional get and set methods as required to provide access to the field(d) Finally, define another class called TestTextbooks with a main() method to perform necessary testing for the classes defined in the previous sections. In the main method, write the code to create at least two objects of the ProgrammingTextbook class and at least two other objects of the EngineeringTextbook class. Create an ArrayList object to store references to these objects and then test various methods of the objects using loop(s) and methods as necessary. Ensure that the program is appropriately documented throughout and thoroughly tested to demonstrate its correct operation.Task 3Value: 4 marksWrite a Java program using JavaFX that displays five playing cards. In the first row display three playing cards (randomly selected from the first 52 cards). In the second and third rows display a Joker card at 45 degree and 90 degree angles respectively. The image icons used in the questions are available in the Resource folder of Interact2. You may need to use HBox and/or VBox Pane. Task 4Value: 3 marksInvestigate the imperative programming paradigm, as exemplified by procedural programming and object-oriented programming, and the declarative programming paradigm, as exemplified by functional programming and logic programming.The Reading from Brookshear, 2012 will form a starting point for your investigation. For further investigation, remember that you should not reference Wikipedia items in an essay, so make sure to find articles that you can reference.Write an essay, of approximately 800 words, based on your investigation, which provides answers to the following questions:What are the essential differences between the paradigms?What are some of the programming languages used for these different paradigms?What specific advantages are provided by these different programming approaches?Your essay should be referenced using the APA referencing style.Rationaleto interpret and evaluate design requirements expressed in Unified Modelling Language (UML) (objective 2);to apply inheritance and aggregation patterns in the design and implementation of programs (Objective 3);be able to compare and critically evaluate different programming paradigms (Objective 6);to manipulate file operations through Java programming; (objective 7);to use object-oriented techniques and Java resources to develop small applications consisting of a number of classes (objective 4);to implement Graphical User Interface) (GUI )components using Java (objective 8).Marking criteriaThese criteria will be used to evaluate Assignment 3:The tasks are performed as specified and the assignment is submitted as requiredAppropriate understanding of the subject area is demonstrated, including correct use of approriate techniquesExplanations and discussions are cogent and use clear and correct English expressionReferencing is used where appropriatePresentationMaterial to submit for Task 11.You need to submit the java and class files2.You also need to submit a doc/pdf file with following information:a.Analysis: Describe the problem including input and output in your own words (not more than 400 words)b.Testing: Describe how you test this program (not more than 400 words)c. Output: Copy and paste a snapshot of the program outputMaterial to submit for Task 21.You need to submit the java and class files2.You also need to submit a doc/pdf file with following information:a.Analysis: Describe the problem including input and output in your own words (not more than 400 words)b.Testing: Describe how you test this program (not more than 400 words)c. Output: Copy and paste a snapshot of the program outputMaterial to submit for Task 31. You need to submit the java and class files2. You also need to submit a doc/pdf file with following information:a. Analysis: Describe the problem including input and output in your own words (not more than 400 words)b. Testing: Describe how you test this program (not more than 400 words)c. Output: Copy and paste a snapshot of the program output Material to submit for Task 41. You need to submit a doc/pdf file which includes the easy.RequirementsTo complete this assignment you might need to have covered material up to and including the topic Inheritance and Polymorphism, abstract classes and interfaces, Thinking of Objects, GUI basics, and UML in the Text Book and module.
Arizona State University Python File Script Coding Sample Run
InstructionsFor each part of the lab; create a python file with the name; part#-ASURITE.pywhere # is the part of the labAS ...
Arizona State University Python File Script Coding Sample Run
InstructionsFor each part of the lab; create a python file with the name; part#-ASURITE.pywhere # is the part of the labASURITE is your user nameExample: part1-cjingers.py, part2-cjingers.pySubmit all .py files as part of your submissionDon't forget the interpreter line!The output of your script must match the same format shown in the sample run for each part.Part 1 Write a Python script that will prompt the user for monetary value (such as 11.26). Then, calculate the number of dollars, quarters, dimes, nickels, and pennies. Your solution should use the maximum possible number of dollars, then quarters and so on. For example; converting 11.26 to 1126 pennies is not acceptable.Sample runEnter an ammount of money: 11.56Your amount of $11.56 consists of; 11 dollars 2 quarters 0 dimes 1 nickels 1 penniesPart 2Given two points, the formula for computing distance is;(x2−x1)2+(y2−y1)2−−−−−−−−−−−−−−−−−−√(x2−x1)2+(y2−y1)2Write a Python script that prompts the user for two points and computes the distance between them.A point is comprised of two floating point numbers; representing the x and y coordinates.Sample runEnter x1 and y1 for Point 1: 1.5, -3.4Enter x2 and y2 for Point 2: 4, 5The distance between (1.5, -3.4) and (4, 5) is 8.8
NVCC Programming Codes Mistake Loops & Step Value Questions Discussion
Answer questions in the order provided and in detail (NOT Summary answer) What is an advantage of using fewer instruc ...
NVCC Programming Codes Mistake Loops & Step Value Questions Discussion
Answer questions in the order provided and in detail (NOT Summary answer) What is an advantage of using fewer instructions?What are the three steps that should occur in every loop?What is the difference between a definite loop and an indefinite loop?Explain when it would be appropriate to write an indefinite loop.What are common mistakes made by programmers in coding loops?What is a step value?When are you required to use a for statement, and what are the advantages of for statements?What is an accumulator?
Please complete Honors Programming Assignment- Programming Assignment 2
Please complete Honors Programming Assignment- Programming Assignment 2The tutor should be familiar with Terminal or Pytho ...
Please complete Honors Programming Assignment- Programming Assignment 2
Please complete Honors Programming Assignment- Programming Assignment 2The tutor should be familiar with Terminal or PythonI already attached (Assignment_2.tar.gz) file for you You can also download (Assignment_2.tar.gz) file from the following linksAssignment_2.tar.gzhttps://d3c33hcgiwev3.cloudfront.net/_e20ed72f0f03...please find the attached files for more details .Thanks
CMPEN 472 Pennsylvania University Arithmetic Instructions and Basic System Worksheet
Due: March 8, 2021 11:30pm
Objective
To learn how to use arithmetic instructions and write basic s ...
CMPEN 472 Pennsylvania University Arithmetic Instructions and Basic System Worksheet
Due: March 8, 2021 11:30pm
Objective
To learn how to use arithmetic instructions and write basic system I/O subroutines. Learn user interface through a serial port.
Instruction
Write a user-friendly system program for the following commands:
S: Show the contents of memory location
W: Write the data byte to memory location
QUIT: Quit the main program, run 'Type writer' program.
Command S: This command shows the contents of memory location specified by the address in hexadecimal number followed by the 'S' character. For example, if the data $6A is stored in memory location $3000, a user types in the first line ending with Enter/Return key and the following should be displayed on the HyperTerminal connected to the HCS12 board:
>S$3000
$3000 = $6A 106
>
The data $6A is printed in both hexadecimal and decimal number format. The character '>' is the prompt for this program.
Command W: this command writes data into the memory location specified by the address in hexadecimal followed by the 'W' character. The data to be written to the memory location is followed by a space and it can be specified by hexadecimal '$' or just decimal number. For example, if one wants to store the data $6A in memory location $3001, a user types in the first line ending with Enter/Return key and the following should be displayed on the HyperTerminal connected to the HCS12 board:
>W$3001 106
$3001 = $6A 106
>
Or
>W$3001 $6A
$3001 = $6A 106
>
As a result, the data $6A is stored in the memory location $3001 and it is shown with the 'S' command. The 'W' command accepts both '106' or '$6A' as an 8 bit number.
For HCS12 chip, assume memory address is a 16 bit number and each memory location hold an 8 bit data.
Design the program to start at $3100 and data to start at $3000.
Make your program user-friendly and fool proofed. Print detail guide on the terminal screen so that users will properly use your program. Once your program is running, everything must be self-explanatory to user at the Hyper Terminal.
For this homework, you must do error checking to see if correct input is entered by a user. And give correct command usage example if invalid command was entered. Your program must NOT crash or hang if a user enters wrong input.
The HyperTerminal display should look something like the following:go 3100 Welcome to the Simple Memory Access Program! Enter one of the following commands (examples shown below) and hit 'Enter'. >S$3000 ;to see the memory content at $3000 > $3000 = $6A 106 > >W$3001 $6A ;to write $6A to memory location $3001 > $3000 = $6A 106 > >W$3001 106 ;to write $6A to memory location $3001 > $3000 = $6A 106 > QUIT ;to the Simple Memory Access Program Type writing now: >S$30G0 > invalid input, address > >S$30123 > invalid input, address > >S345678 > invalid input, address > >W$3001 $6AB > invalid input, data > >W$3001 300 > invalid input, data > >W$3001 > invalid input, data > >W$3001 -106 > invalid input, data > >W$3 $0F > $0003 = $0F 15 > >W$300 $9 > $0300 = $09 9 > >W$4000 12 > $4000 = $0C 12 > >W$0001 005 > $0001 = $05 5 >
You may want to first draw the Flow Chart of the above algorithm.
Be sure to put much comments so that grader and others can clearly and quickly understand your program. Comments are very important in assembly language programs.
You may want to see and check the Sample Grading Sheet for this homework.
Copy your 'main.asm' file to 'cmpen472hw6_YourLastName.asm'. For example, mine will be 'cmpen472hw6_choi.asm' Then turn-in your .asm file (do NOT ZIP your file).
Turn-in your project source code file through Penn State CANVAS. Upload your source code file into the CANVAS Assignment's Homework submission. Be sure to select CMPEN 472 class and correct Homework number, and with correct file name.
Congratulations on your sixth CMPEN 472 homework completion!
Here is a link for the codewarrior idle install https://drive.google.com/file/d/19HVtjjhX8aJEh2oDa...
Earn money selling
your Study Documents