Week 13 of Cow Goes Moo was a tragic week. This week, for 2 classes we did not work on Visual Basics because of lack of people in class and for a tragic reason. On Monday, we were given a class to finish up a program that determines high, low and average of the marks entered by the user that we started last week. Fortunately I already had it finished last week. I got to work on other subject works in that class.
The other 2 days where I actually worked on some stuff, we learned something new called Arrays. An array is a data structure that stores variable data that has the same data type. It is a group of variable that is given only one name. Each variable that makes up the array is given a number instead of a name which makes it easier to work with using loops among other things. We declare by Dim ArrayName(ArraySize) as DataType. We used this structure to create a program that does several things. It can initialize elements of the array to one, initialize elements of the array with random numbers between 1 and 50, switch the values at either end of the array, and input 10 numbers from the user to change the negative value to positive, calculate the sum of all the numbers and to calculate the product of odd numbered position in product.
This week, I completed the first program using the array structure. However I did not yet get started on the second program and the third program using arrays. I'm expected to work on and finish them next week.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment