Basics of Writing Code 2 Practice Time in Verse
Ready to write some code?
-
Open your hello_world_device.verse file from Modify and Run Your First Verse Program. You can see a couple of examples of the
Print()function in the file already. -
Use
Print()to see the effect of combining different operators and literal values. Enter the first line of code below. Work out what will print to the screen before you run the line, then run it to see if you were right.| | | | --- | --- | | | Print("5 + -2 = {5 + -2}") | | | Print("15.0 / 7.0 = {15.0 / 7.0}") | | | Print("I + Love + Verse = {"I" + "Love" + "Verse"}") |Print("5 + -2 = {5 + -2}") Print("15.0 / 7.0 = {15.0 / 7.0}") Print("I + Love + Verse = {"I" + "Love" + "Verse"}")
Copy full snippet(3 lines long)
-
Repeat this step for the second line (including working out what should print), then again for the third line.
-
Now copy and paste this line to see what happens!
Print("🐈💗🐟 = {"🐈💗🐟"}")
Complete Script
This is all of the code covered in this exercise. If you get stuck, you can see what the complete script looks like and even copy and paste it into your own Verse file to see the correct end result.
You're reading a preview
The full reference is free for BrainDeadGuild Discord members — sign in to read it all, or open the original at the source.
Sign in with your BrainDead.TV / BrainDeadGuild Discord account for full access.