I want to multiply the first two numbers of a digit together and subtract the third from it!
Mostrar comentarios más antiguos
I have the number
223456
I want to multiply the first two digits together and subract by the third. example from above: 2*2-3
I have made the number into a string using the following:
%convert the number to individual digits digits = code_string - '0';
so as far as I know the matrix looks like: [2 2 3 4 5 6] and again I want to multiply the first number by the second and subtract the third.
Thanks!
Lucky
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Characters and Strings en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!