Meaning of the “Dim” keyword in Basic

In: Programming

19 Dec 2008

Visual Basic is my favourite programming language. And sometimes I used to winder what does the Dim in a variable declaration stand for. I had read about it sometimes back but I did not remember much, today I Googled up a bit and found the meaning.

Dim stands for Dimension. It was used for declaring the size of an array.

Dim Arr(100)

So here we are declaring an array with the size of 100 (Actually 101 because in Basic it goes from 0-100 as against 0-99 in any other C based language like Java or C#)

The same keyword was extended to declare scalar(single value) variables e.g. Dim i as integer

Source

SocialTwist Tell-a-Friend

Comment Form

About this blog

This is the blog of Yash Gadhiya. An entrepreneur from Mumbai, India. I write about tech, science, history, cats, movies, politics, atheism, design, programming and myself!

  • Jason Webb: I hope Entrepreneurship is about doing something you like to do that fills a need or satisfies a wan [...]
  • Lalit: I got this one a few times too ... [...]
  • manish: I fully agree with the comments above. This is most stupid phone that I ever used nokia. [...]
  • ROY JOSEPH: I fully agree with the comments above. This is most stupid phone that I ever used. I regret v [...]
  • Pedro: Hello, I just received an email just the same! I also thought to the same way you did. Thanks for yo [...]