Docsity

CS0004 Assignment 4: Array and Structure Manipulation, Assignments of Computer Science

Toggle sidebar
bg1
CS0004 Written Assignment 4 Due 03/25/2007
1. What is the difference between the upper bound of an array and the size of an array
2. Let “nameArray” be an array of Strings. How would you find the upper bound of this array?
3. Write a small loop to convert all the elements in “nameArray” to upper case.
4. How would you open (and create a communication channel) for a text file called “data.txt” in
VB? (show me the code)
5. Consider the following list of numbers in an array: 34|22|1|4|9|4|45|0|23|12
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?
pf2

Partial preview of the text

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/

  1. What is the difference between the upper bound of an array and the size of an array
  2. Let “nameArray” be an array of Strings. How would you find the upper bound of this array?
  3. Write a small loop to convert all the elements in “nameArray” to upper case.
  4. How would you open (and create a communication channel) for a text file called “data.txt” in VB? (show me the code)
  5. 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?
  1. What is a structure? And why is it important?
  2. Create a structure called “Car” that contains the following information: make, model, year, color
  3. Write a simple loop that takes an Integer array called “numbers” and sets every element to 1
  4. What will be the value returned by the following function call Asc(“A”)?
  5. What will be the result of Chr(Asc(“A”)+2)?