Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

how come this doesn't work?

Asked by
yoyyo75 74
9 years ago

print yoyyo75 it errors for some reason and i don't understand why

1 answer

Log in to vote
1
Answered by
davness 376 Moderation Voter
9 years ago
print yoyyo75

1. You are printing a value that the computer does not know what is it.

2. Print is a function, so you need to use parenthesis () - or not, depending of what you type it.

You may do:

print 'yoyyo75'
--or
print("yoyyo75")
--or
print('yoyyo75')

OUTPUT: yoyyo75

or you can say that yoyyo75 is something, like this

local yoyyo75 = 'hello!! :)' -- we are telling to the computer that saying yoyyo75 is the same of saying 'hello!! :)'
print(yoyyo75)

OUTPUT: hello!! :)

When we have a value like this "dav1000999" or 'dav1000999', we say we have a string value (a value which carries text)

Ad

Answer this question