Extract Numbers From String


I am trying to extract a couple of numbers from a string receive from API call. Example of string;

  1. 30*40*120
  2. 30*300*230*4

I want to extract each number string and convert it to numbers, and do calculation. Anybody know the best way to do this?

Thank you in advance.

anybody can help me with this? or @Bubble can guide me?

Bump up this question. Anybody knows how to do this? I need to separate the numbers in the string so that I can calculate.

You need to use Regex. Each operation in Regex has a unique code.

I don’t have the code for this operation but you can search on google and find it easily.

This topic was automatically closed after 70 days. New replies are no longer allowed.