MATLAB: Spliting a date to day, month and year

Hello,
Suppose I have a date in this form only : 14/2/1923 or 8/2/1923 (not 14/02/1923 or 08/02/1923)
How can I split it to day, month and year? there are no zeros at all in the date.
Thank's!

Best Answer

myDate = '4/2/1923';
mySplitDate = regexp(myDate,'/','split');
myDatevec = cellfun(@(x) str2double(x),mySplitDate)
Related Question