Skip to content

Prompt command

Alvin Cheng edited this page Feb 2, 2023 · 1 revision

Description

Every programming language/computer system must have a way to BOTH input and output data/a signal, this is exactly what this command is for! Particularly inputting data!!! Anyhow, let's get down to business! So, The prompt command uses the built-in standard terminal input from nodeJS to allow users of your program to input plain-text data. This command will take 2 arguments, the first argument is for the text to prompt the user. And the second argument for the variable to return the inputted data. Here is a working example below 👇

Example

$VARIABLE = (prompt "<PROMPT>");

Nice and simple!! Let's go!

Clone this wiki locally