Is there a command like 'scanf' in GNU Octave to read the user inputs from the keyboard?
Yes, the function is called input
. A simple example:
octave-3.2.4:3> x = input("Enter a number: ")
Enter a number: 25
x = 25
See the documentation for details, like overriding the default parsing behavior.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With