Create a generic bubble sort method

Assignment Help Visual Basic Programming
Reference no: EM132321015

Programming Languages and Logics Assignment -

1. Bubble Sort

Create a generic bubble sort method. Refer to the file attached to the Blackboard assignment for this test, BubbleSortTest.cs, for an implementation of a non-generic Bubble Sort. Your method must be able to sort an array of any type of objects that implements the IComparable interface. The method is also to have a bool parameter called isAscending to indicate whether the array is to be sorted in ascending or descending order. Create a main method that creates an array of 50 integers. The integers are to be randomly selected, ranging from 0 to 99, inclusive. Also create an array of 50 strings. The strings are to be randomly generated, consisting of only lowercase letters, and ranging in a randomly selected length from 1 to 10 characters. Display the contents of both arrays before sorting, after sorting in ascending order, and after sorting in descending order.

2. Count Numbers

Write a program that reads an unspecified number of integers and prints the numbers and their count of occurrences sorted in ascending order first by number, and then by the number of times they occur. The input ends when the input is 0. For example, if you entered 2 3 3 5 4 -3 3 3 2 0, the output would look something like:

Number

Count

-3

1

4

1

5

1

2

2

3

4

The program should be implemented using a SortedDictionary to track occurrences, and use LINQ to sort the results. The LINQ used may either be SQL or method syntax.

3. Sorting Letters and Removing Duplicates

Write a console app that inserts 30 random letters (Upper and Lower case) into a List<char>. Perform the following queries on the List and display your results:

1. Use LINQ to sort the List in ascending order.

2. Use LINQ to convert all of the letters in the List to upper case, filter the list so it only contains characters from M-Z, and sort the List in descending order.

3. Display the List in ascending order with duplicates removed.

Attachment:- Assignment Files.rar

Reference no: EM132321015

Questions Cloud

What steps would you need to take in order to solve issue : What steps would you need to take in order to solve the issue? Does anyone else at the school need to be involved in the solution?
How will increasing level of education in future of nursing : How will increasing your level of education affect your role in the future of nursing? While APA format is not required for the body of this assignment.
Describe the causes and treatment of thrombocytopenia : Acting case study forum. Each student will be subdivided into group of 5 students. Each group will be assigned a case study for which the group will need.
Research a job field that you already work in : To show through documented examples or expert quotations how people can use this occupation as a platform for advancing something that God values.
Create a generic bubble sort method : CS 5110 - Programming Languages and Logics Assignment, Cornell University, USA. Create a generic bubble sort method
Compare clinical significance and statistical significance : Compare clinical significance and statistical significance; include which one is more meaningful to you when considering application of findings to nursing.
Does more technology use improve time with patients : Explore the role of advancement in information technology and its effect in patient care. Does more technology use improve time with patients?
Two mechanisms for improved information sharing : Describe at least two mechanisms for improved information sharing. How do the mechanisms you selected either help or create challenges for sharing information
Do you believe the proposal would be approved : Share your written proposal with your manager in a formal leadership position within a health care organization. Request their feedback using the following.

Reviews

len2321015

6/12/2019 10:29:05 PM

Please follow the directions, and submit the zipped C# Solutions for each question. Instructions - Submit the files in the designated slot on Blackboard. You are required to work independently. You are not permitted to receive assistance from classmates or other individuals. You may reference the textbook and course materials as well as the C# documentation. You are not permitted to use code from sources other than the course materials and textbook examples and previous programming assignments. Ensure your programs run properly with C# and Visual Studio 2017 or 2019. Submit files by the due date indicated on Blackboard. Good luck!

Write a Review

Visual Basic Programming Questions & Answers

  Triangle of asterisks write a program that displays the

write a program that displays the following patterns separately one below the other in a textbox. use for...next loops

  Draw a sketch of the user interface

Listed below are the four steps you should follow when planning an 00 application. Put the steps in the proper order by placing a number (1 through 4) on the line to the left of the step. Draw a sketch of the user interface. Identify the tasks the ..

  Car rental agency assignment

PROJECT GUI MINIMUM REQUIREMENTS - Combo boxes, Option Buttons, and Checkboxes must interact with at least one Text Field or other control and a minimum of two fields must not be editable and their contents must be generated from other component inte..

  Create project to display flags of four different countries

Create a project to display flags of 4 different countries depending on the setting of a radio button, into a single display box. In addition, display the name of the country under the flag display box.

  Create a sub procedure that calculates and displays the next

A national Digital service provider would like you to create a Windows application that will display the global growth of smartphones. As of 2013, there 913 million smartphones worldwide.

  Performing a calculation on that value

Individual Visual Logic Calculations. Select two to three Each task must include the following Inputing a value. Performing a calculation on that value. outputting the value. produce Visual Logic files to execute each of these steps.

  Calculate and display cost for operating a home appliance

Validate that the data entered has the correct format, and is within a reasonable range. Calculate and display the cost for operating a home appliance as soon as the data is entered.

  Implement bresenhams line algorithm

300029 ENGINEERING VISUALIZATION - Laboratory Practical - 2D GRAPHICS - Scan-convert lines using the mid-point line algorithm - Implement Bresenhams line

  Display in message label when statements are executed

What will display in MessageLabel when the following statements are executed? Assume that CountInteger = 10. MessageString = "Visual Basic is fun" IF CountInteger

  Gas pump create an application that stimulates the

create an application that stimulates the functionality of the gas pump. user enters the number of gallons to purchase

  Write a program that computes an average score for a class

When the user presses the OK button, the items contents should update in the ListView control.

  Define access keys for the buttons in the user interface

Define access keys for the buttons in the user interface. Provide input fields where the amount of each type of fuel to be purchased can be entered.

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