인프런 영문 브랜드 로고
인프런 영문 브랜드 로고

Inflearn Community Q&A

김동찬's profile image
김동찬

asked

[MMORPG Game Development Series with C# and Unity] Part 1: Introduction to Basic C# Programming

Multidimensional array

배열의 저장 장소

Written on

·

262

0

안녕하세요

배열 초기화 방법 중

int[] scores = new int[]{ 1, 2, 3, 4, 5}

이런 방법이 있고 점점 생략을 해서

int[] scores = {1, 2, 3, 4, 5}

이런 방법이 있다고 하셨는데

밑에 방법은 일반적으론 stack에 저장되는것처럼 보이는데 new int[]를 생략을 한거니 heap에 저장되는게 맞을까요?

C#

Answer 1

0

rookiss님의 프로필 이미지
rookiss
Instructor

네 원본 데이터는 heap에 저장됩니다.

김동찬's profile image
김동찬

asked

Ask a question