Filling an array with the same words.

조회 수: 6 (최근 30일)
Mike Hodny
Mike Hodny 2018년 2월 15일
답변: Birdman 2018년 2월 15일
Hello, I would like to fill a 1 to n array with the same word, but I don't want to have to type it all out.
Ex:
[text, text, text, text]
How can I do this? Thank you in advance.

채택된 답변

Birdman
Birdman 2018년 2월 15일
n=10;
repmat(["text"],1,n)

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Cell Arrays에 대해 자세히 알아보기

태그

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by