A university assignment focusing on arrays and structures in computer science. Topics include the difference between array upper bounds and sizes, finding array upper bounds, converting array elements to upper case, opening a text file in visual basic, bubble sort algorithm, structures, and their importance. Students are required to complete various tasks such as writing loops and function calls.
Download CS0004 Assignment 4: Array and Structure Manipulation and more Assignments Computer Science in PDF only on Docsity!
CS0004 Written Assignment 4 Due 03/25/
What is the difference between the upper bound of an array and the size of an array
Let “nameArray” be an array of Strings. How would you find the upper bound of this array?
Write a small loop to convert all the elements in “nameArray” to upper case.
How would you open (and create a communication channel) for a text file called “data.txt” in VB? (show me the code)
Consider the following list of numbers in an array: 34|22|1|4|9|4|45|0|23| a. After the first pass of the Bubble sort algorithm, what will be the contents of the array? b. How about after the second pass?
What is a structure? And why is it important?
Create a structure called “Car” that contains the following information: make, model, year, color
Write a simple loop that takes an Integer array called “numbers” and sets every element to 1
What will be the value returned by the following function call Asc(“A”)?