Suppose i have two strings a and b
a = {'two' , 'three' , 'four'}
b= {'five','six','seven'}
I want output as C
C= {'two','three','four','five','six','seven'}
I tried using strvact and strcat but it doesn't work. What should be used to get c in terms of and b?

 채택된 답변

galaxy
galaxy 2019년 10월 23일

1 개 추천

C = horzcat(a, b)

댓글 수: 2

Akira Agata
Akira Agata 2019년 10월 23일
Or simply:
C = [a,b];
Rohit Deshmukh
Rohit Deshmukh 2019년 10월 23일
Thanks a ton both of you :)

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

질문:

2019년 10월 23일

댓글:

2019년 10월 23일

Community Treasure Hunt

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

Start Hunting!

Translated by