How to select a character array if it has a specific end value

조회 수: 2 (최근 30일)
Elena
Elena 2022년 2월 24일
편집: Elena 2022년 2월 24일
say this is my input:
emails = 'myemail@gmail.com, random@yahoo.com, notanemail'
I would only want to select the values that contain @gmail or @yahoo (etc.) so not the last one becasue it's not an email. How could i do this?

채택된 답변

Steven Lord
Steven Lord 2022년 2월 24일
See the split and contains functions.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Manage Products에 대해 자세히 알아보기

태그

제품


릴리스

R2021a

Community Treasure Hunt

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

Start Hunting!

Translated by