Calculates the total difference between two numbers
38 Ansichten (letzte 30 Tage)
Ältere Kommentare anzeigen
I want it to calculate the difference between two given numbers.
1 Kommentar
Antworten (1)
Guru Kumaresan
am 9 Nov. 2022
Bearbeitet: Guru Kumaresan
am 9 Nov. 2022
Hi Adam,
I understand that you are trying to find the difference between two numbers. For this purpose, you can use absolute value function available in MATLAB.
Example:
a = 2;
b = 5;
Diff = abs(a-b);
Diff will have the value of 3.
Hope this helps!
0 Kommentare
Siehe auch
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!