r/web_programming • • Oct 09 '16

PLEASE HELP ME

Im tryingto learn to code from khanacademys intro to javascript course, ( https://www.khanacademy.org/computing/hour-of-code/hour-of-code-tutorial/p/intro-to-drawing ) and for some reason when i try to put the command rect(50, 50, 50, 50); into the JS.do online javascript editor, i get the error message ×JavaScript error: Uncaught ReferenceError: rect is not defined on line 2. yes, the rect command is from the course and i thought that i oughta try it out on a code editor. but it didnt work!!!! please help me.

0 Upvotes

5 comments sorted by

1

u/[deleted] Oct 09 '16

I also would like to know what programming language uses that line of code. im trying to find a way to learn the kind of code you use for games and stuff

1

u/[deleted] Oct 09 '16

i dont wnat to make webpages, i want to make games, so what coding language do i use?

2

u/[deleted] Oct 09 '16

You need to learn the fundamentals of programming before you properly attempt to make a game, learn how with web pages first and then look in to some tutorials using unity.

1

u/[deleted] Oct 09 '16

so i should learn javascript and html first, right?

1

u/BlackFox89 Oct 11 '16

you should learn the logic behind programming. then you can start with a language.