digital literacy for everyone
[[variables]] | /input/ | [[output]] | [[basic-math]] | [[loops]] | [[conditionals]] | [[functions]]
quasi is a very young language, and input methods are extremely limited. since part of the quasi interface is a small program editor, technically editing variable assignments is like "input", but thats not great.
for example, if you bookmark or make a link that just says "hello", and link it to quasi 3.9 or later, command will let you access it:
will get the contents of the link after the question mark ? and store each item after it in the variable *now*. if you then output the contents, it will show the word "hello" on the screen.
the *date* command is technically an input command as well. if you use the *date* command, you will get an array including the date, time and day of the week:
you can use other commands to isolate the information you want from this array.
apart from introducing quasis concept of input, these commands demonstrate a convention that adds to our concept of how the language works--
in the section on variables, we learned that you could set the value of a variable by providing a number or string:
height get 5
firstname get "alan"
in this section, instead of setting the variable on the left to a known value, we set the variable to the value that a quasi command provides-- either *date* for information from the system clock, or *command* for information included in the url linking to quasi.
we learned about strings in the previous section, where we set firstname to the string "alan".
in the examples of date and command, it actually sets the variable on the left to an array of strings. each item in the array is a separate string, which we can access individually or as a group.
so far, we have learned how to set a variable and how to get information from a link and from the clock. these examples create data that the program has access to, but that isnt useful to us unless the program can [[output]] information as well.
please note, that if you are reading these sections and expect to understand coding from them, you really should be entering the code into quasi and clicking *run program*.
it is possible to learn how quasi works just in theory, just like you dont need to count beans or sticks to know that 2 + 2 = 4, but typing and running code is a far more powerful way to watch and learn what code does in practice, not just in theory.
when you can watch the code working, it means far more to the learner than "this is how a program would work, if i actually ran it." you can run quasi here: [url]https://codeinfig.neocities.org/quasi/quasi40.html?here is some text[url]
you can also right-click and download the above file; quasi is a single html file, with all the necessary program language implementation included. this means you can run quasi without an internet or network connection.
back to quasi concepts: [url]https://codeinfig.neocities.org/quasiconcepts/index.html[url]
quasi main page: [url]https://codeinfig.neocities.org/quasi/index.html[url]