昏暗V之间的差值作为字符串()和暗淡v()作为字符串是什么? [英] What is the difference between Dim v As String() and Dim v() As String?

查看:197
本文介绍了昏暗V之间的差值作为字符串()和暗淡v()作为字符串是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这听起来可能微不足道,但什么是暗淡V之间的差值作为字符串()和暗淡v()作为字符串在VB.NET?

This may sound trivial, but what is the difference between Dim v As String() and Dim v() As String in VB.NET?

推荐答案

没有区别。从 VB.NET语言规范的阵列

数组类型是通过添加改性剂到现有的类型名称指定。改性剂包括左括号,一组零个或多个逗号和一个右括号。

Array types are specified by adding a modifier to an existing type name. The modifier consists of a left parenthesis, a set of zero or more commas, and a right parenthesis.

...

一个变量也可以宣布通过把一个数组类型修饰符或在变量名称的数组初始化修改是一个数组类型。在这种情况下,数组元素类型是在声明所给出的类​​型,并在阵列尺寸由变量名改性剂来确定。 为清楚起见,它是无效的在同一个声明

A variable may also be declared to be of an array type by putting an array type modifier or an array initialization modifier on the variable name. In that case, the array element type is the type given in the declaration, and the array dimensions are determined by the variable name modifier. For clarity, it is not valid to have an array type modifier on both a variable name and a type name in the same declaration.

这篇关于昏暗V之间的差值作为字符串()和暗淡v()作为字符串是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆