Question: Which of the two following Visual BASIC statements is incorrect? Why?
x = x + 1
a + b = c + d
For the foregoing Dim statements, you could not include the line
a = “October 1, 1998”
This would result in an error message, because you’re telling the computer to put a square
peg in a round hole; that is, you’re telling it to store a string constant in a real, single
precision memory location. If you do this, the program will not execute and you’ll get an
error message.
then how should we enter a?
if say:
dim as a constant
will this be correct?
Arrays:
It says, instead of subscripts, parenthesis is used.
b1=a11*x1 + a12*x2
b(1) = a(1, 1) * x(1) + a(1, 2) * x(2)
We know a12 means that a to be multiplied by itself 12 time.
What does a11 mean?
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++=
An array defined as
Dim a (10, 10)
What does it say? Does it mean the array is two dimensional and it has 10 elements?
x = x + 1
a + b = c + d
For the foregoing Dim statements, you could not include the line
a = “October 1, 1998”
This would result in an error message, because you’re telling the computer to put a square
peg in a round hole; that is, you’re telling it to store a string constant in a real, single
precision memory location. If you do this, the program will not execute and you’ll get an
error message.
then how should we enter a?
if say:
dim as a constant
will this be correct?
Arrays:
It says, instead of subscripts, parenthesis is used.
b1=a11*x1 + a12*x2
b(1) = a(1, 1) * x(1) + a(1, 2) * x(2)
We know a12 means that a to be multiplied by itself 12 time.
What does a11 mean?
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++=
An array defined as
Dim a (10, 10)
What does it say? Does it mean the array is two dimensional and it has 10 elements?