Is it faster (or better) to declare an array inline in Java?

前端 未结 7 1259
慢半拍i
慢半拍i 2021-01-11 17:20

Consider the following two method calls that are nearly equivalent. Take note of the way the byte array is declared and allocated on both.

void Method1()
{
          


        
7条回答
  •  庸人自扰
    2021-01-11 18:03

    There is no difference between both the ways. It's just 'Syntactic sugar' in syntax.

提交回复
热议问题