extract numbers from a char type input

2 次查看(过去 30 天)
Hi everyone, my question is about how can i seperate the two numbers given by the user in the form "number1,number2" that are stored as a char type vector. So basicaly i want to seperate it where the comma is and keep the values left and right.
Thanks in advance.

采纳的回答

per isakson
per isakson 2012-5-5
Try
doc strtok
and
doc str2num
  1 个评论
Raldi
Raldi 2012-5-5
thank, i believe this is what i was searching for. Although i did it manualy :P

请先登录,再进行评论。

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Logical 的更多信息

标签

产品

Community Treasure Hunt

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

Start Hunting!

Translated by