Create a generic bubble sort method
Course:- Visual Basic Programming
Reference No.:- EM132321015

Assignment Help
Expertsmind Rated 4.9 / 5 based on 47215 reviews.
Review Site
Assignment Help >> Visual Basic Programming

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:













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

Put your comment
View Conversion
  1. user image

    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!

Ask Question & Get Answers from Experts
Browse some more (Visual Basic Programming) Materials
Provide a brief summary of the background, charges, and trial of this high-profile court case.Explain, from a forensics perspective, the digital evidence found on the Anthony
Your project will consist of programming a basic 4 function calculator with an on and off button. Such task usually primitive and essay to implement however the thing that w
Create a Visual Basic Windows application. Use the following names for the solution, project, and form file, respectively: Conway Solution, Conway Project, and Main Form.vb.
Write a menu-driven program to manage a membership list. Assume that the names and phone numbers of all members are stored in alphabetical order (by last name and then by fir
Which of the following is a valid variable name in Visual Basic? Which of the following statements declares a variable named dblHeight with data type Double in Visual Basic?
The aim of the assessment is to develop a Visual Basic console application that performs a number of mathematical functions. The mathematics package will be menu driven, i.e.
What do you understand by event driven programming? List and explain about some of the events supported by Visual Basic Objects - what are the different data types supported
Create an application that calculates the total cost of a hospital stay. The application should accept the following input: The number of days spent in the hospital and The am