Change a character array to time

Hello, I want to change the character array such as '113203' to time(hr:min:sec) 11 hours 32 minutes and 03 seconds. Would you please inform me of how to do it? Thanks in advance and happy Christmas!

 採用された回答

Azzi Abdelmalek
Azzi Abdelmalek 2014 年 12 月 25 日
編集済み: Azzi Abdelmalek 2014 年 12 月 25 日

1 投票

s='113203'
a=datenum(s,'HHMMSS')
out=datestr(out,'HH:MM:SS')

1 件のコメント

Yongmin
Yongmin 2014 年 12 月 25 日
Many thanks for your prompt answer. Happy Christmas!

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File ExchangeChristmas / Winter についてさらに検索

タグ

質問済み:

2014 年 12 月 25 日

コメント済み:

2014 年 12 月 25 日

Community Treasure Hunt

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

Start Hunting!

Translated by