Recall user defined variable in another subsequent user input.
Mostrar comentarios más antiguos
body1 = input ('ENTER THE NAME OF THE FIRST CELESTIAL BODY: ','s');
body2 = input ('ENTER THE NAME OF THE SECOND CELESTIAL BODY: ','s');
planrad = input ('ENTER THE DISTANCE BETWEEN THESE TWO BODIES IN (m): ');
massbod1 = input ('ENTER THE MASS OF (body1): ');
massbod2 = input ('ENTER THE NAME OF (body2): ');
I'm asking the user to define the above variables... How can I programm "massbod1" and "massbod2" to automatically insert the user entered text?
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Geoscience 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!