Create a windows application that uses variable arrays

Assignment Help JAVA Programming
Reference no: EM131678272

Part 1

Fulton College wants an application that will allow the lecturers to store information regarding the students and their marks.

Create a Windows application that uses variable arrays to store the student's name and their mid semester marks. (Your application should at least store records for 10 students.)
For example:

Dim strNames() As String = {"Hova", "Nemo", "Zoc", "Lucas", _
"Phuket", "Cindy", "Marlin", "Darla", "Nigel", "Cindrella"}
Dim dblMarks() As Double = {32.5, 88, 90.5, 67.5, 65, 77.5, 85, 78.5, 89.5, 90}

Have a command button that when clicked produces various statistics, such as:

- Average mark

- Highest mark scored and the student who scored it. (* There are no ties) ‘

- Lowest mark scored and the student who scored it (** There are no ties)

- The range (i.e. Highest score - lowest score)

Use functions

Convert the solution to use functions. That is create and use functions for:

- Average mark
This function should accept the dblMarks array as input and return the average as result.

- Highest mark scored
This function should accept the dblMarks array as input and return the highest score.

- Lowest mark scored
This function should accept the dblMarks array as input and return the lowest score.

- The range
This function should accept the highest and lowest score as input and return the range.

Part II: A Program to Analyze Exam Results (using structure arrays)

Modify Part I so that the data on student names and marks are stored in a structure array of type Student.

Declare the following structure at module level:

Structure Student
Public strName As String
Public dblMark as String
End Structure
And then in the click event handler of command button that calculates the statistics; declare a array and populate it with the same data. e.g.
Now in your code for the calculations, every where you used dlbMark, replace that line with
StudentMarks(index).dblMark, where index is the loop control variable

Part III: A Program to Analyze Exam Results (using files and arrays)
Create a file called marks.tx that will store the data on student's name and their mid-term mark Example: Given below are the contents of the file marks.txt.

Create a "File" Menu and then an "Open File" menu item under it. Program the following requirements under the click event-handler of the "Open File" menu item.

- Use a FileOpenDialog dialog box to locate and get the file path for marks.txt (you can download this file and save it in your USB or to any other appropriate directory)

- Once file is selected, open it and using a loop read the entire contents of the file line by line, extracting name and mark and storing them in the names and midterm marks array.

You program will still require the following array (declared at module level), however without the initialization.

Reference no: EM131678272

Questions Cloud

Various ways in which economic crisis affects crime rate : Describe the various ways in which the economic crisis affects the crime rate.
What is present value of the expected euro dividend stream : What is the present value of the expected euro dividend stream if the euro is expected to appreciate 4.00% per annum against the dollar?
Provide your best guess for the identities of the proteins : Provide your best guess for the identities of the proteins you had in each tube, including the biological source. What bioinformatics tool did you use for this purpose? How did you determine the identity of your protein? What factors did you consider..
Why is providing sound guidance on expected demand important : Why is providing sound guidance on expected demand important? Formulate a sound pricing strategy recommendation.
Create a windows application that uses variable arrays : BIIS104 - Create a Windows application that uses variable arrays to store the student's name and their mid semester marks -
Different types of companies : Review HR managers of various companies to better understand the role they play in large and small companies, different types of companies,
What is the net present value and internal rate of return : The initial investment will be made on December 31, 2011, and cash flows will occur on December 31st of each succeeding year.
Discuss a complex process analysis : What type of graphic display is particularly useful for showing a complex process analysis
Deeper layer being denser : The formation of layers in a material, with each deeper layer being denser (weighing more per unit of volume) than the layer above.

Reviews

len1678272

10/13/2017 2:58:38 AM

How to Submit Assignment: o There are 3 parts to this assignment and all are compulsory. Zip all files within a folder before submission. o Should be submitted no later than 5pm, 10% for late submission o The final submission folder should have all the group’s name as the folder’s name. o Submit a group allocation template at the end indicating what each group member did and contributed towards the assignment. o Send the assignment via email.

len1678272

10/13/2017 2:58:20 AM

Objectives At the end of this assignment you should be able to: ? Use For Next Loops with List boxes. ? Learn how to write programs using arrays. ? How to declare and manipulate data into one-dimensional arrays. ? Use appropriate repetition structures to process one-dimensional arrays. ? Access individual array elements. ? How to declare and manipulate data into one-dimensional STRUCTURE arrays. ? Learn how to open and close external (data) files. ? Use File Dialog boxes to locate files. ? Read data from input files and write data to output files (sequential data files) ? Understand the concept of fields and records in sequential files ? Read an entire line from a file (a record) and then breakdown into required fields. ? Use loops to read contents of data files.

len1678272

10/13/2017 2:58:05 AM

Do you have any solution on this activity? Hint: Refer textbook/slides to get the code on how to read lines from a sequential access file, use the split function to extract the name and marks and how to store the values into the structure array. The rest of the program remains the same i.e. a command button that when clicked produces various statistics, such as: • Average mark • Highest mark score. (* There are no ties) • Lowest mark scored. (** There are no ties) • The range (i.e. Highest score – lowest score)

Write a Review

JAVA Programming Questions & Answers

  Recursive factorial program

Write a class Array that encapsulates an array and provides bounds-checked access. Create a recursive factorial program that prompts the user for an integer N and writes out a series of equations representing the calculation of N!.

  Hunt the wumpus game

Reprot on Hunt the Wumpus Game has Source Code listing, screen captures and UML design here and also, may include Javadoc source here.

  Create a gui interface

Create GUI Interface in java programing with these function: Sort by last name and print all employees info, Sort by job title and print all employees info, Sort by weekly salary and print all employees info, search by job title and print that emp..

  Plot pois on a graph

Write a JAVA program that would get the locations of all the POIs from the file and plot them on a map.

  Write a university grading system in java

University grading system maintains number of tables to store, retrieve and manipulate student marks. Write a JAVA program that would simulate a number of cars.

  Wolves and sheep: design a game

This project is designed a game in java. you choose whether you'd like to write a wolf or a sheep agent. Then, you are assigned to either a "sheep" or a "wolf" team.

  Build a graphical user interface for displaying the image

Build a graphical user interface for displaying the image groups (= cluster) in JMJRST. Design and implement using a Swing interface.

  Determine the day of the week for new year''s day

This assignment contains a java project. Project evaluates the day of the week for New Year's Day.

  Write a java windowed application

Write a Java windowed application to do online quiz on general knowledge and the application also displays the quiz result.

  Input pairs of natural numbers

Java program to input pairs of natural numbers.

  Create classes implement java interface

Interface that contains a generic type. Create two classes that implement this interface.

  Java class, array, link list , generic class

These 14 questions covers java class, Array, link list , generic class.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd