In Perl, what is the difference between accessing an array element using @a[$i] as opposed to using $a[$i]?

后端 未结 3 948
臣服心动
臣服心动 2020-12-04 02:19

Basic syntax tutorials I followed do not make this clear:

Is there any practical/philosophical/context-dependent/tricky difference between accessing a

3条回答
  •  眼角桃花
    2020-12-04 02:25

    The first yields a scalar variable while the second gives you an array slice .... Very different animals!!

提交回复
热议问题