Decision Branching, modification Script

Modify the script so that the plotting code on lines 4-7 are executed only when doPlot is 1.
plot(density)
title("Sample Densities")
xticklabels(element)
ylabel("Density (g/cm^3)")

 Akzeptierte Antwort

Dhruv G
Dhruv G am 5 Jul. 2021

1 Stimme

if doPlot
plot(density)
title("Sample Densities")
xticklabels(element)
ylabel("Density (g/cm^3)")
end

Weitere Antworten (0)

This question is locked.

Produkte

Tags

Locked:

DGM
am 16 Aug. 2024

Community Treasure Hunt

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

Start Hunting!

Translated by