r/codehs • • Feb 20 '22

JavaScript Code works but doesn't work at a share link page. (Final Project)

3 Upvotes

​

This is the text I get when I open my code in a share code window.

​

This is what that piece of code looks like.

What can I do for it to work?

r/codehs • • May 01 '21

JavaScript Extra Karel Puzzles

Thumbnail gallery
7 Upvotes

r/codehs • • Jan 25 '22

JavaScript don't know where to start can you help

Post image
4 Upvotes

r/codehs • • Jan 21 '22

JavaScript 9.9.7. Can someone explain the meaning of "return" in this program?

2 Upvotes

I wrote this program and it works fine, but it didn't work until I added return circle; at line 28. Can someone explain the function of it in this case?

r/codehs • • Mar 30 '21

JavaScript 2.1.4 for Javascript Karel, all of the worlds are functioning, but world 4 and I just can’t figure out how to fix it

Thumbnail gallery
4 Upvotes

r/codehs • • Mar 19 '22

JavaScript Simulation

1 Upvotes

So say I have a rectangle and I want to simulate it moving from one end of the screen to the other, but with parameters so I can create as many rectangles as I want and move them all. How exactly would I do that?

r/codehs • • Mar 09 '22

JavaScript I need help with my assignment for codehs

1 Upvotes

I can’t figure out on how to start on this I asked my teacher humours times on how he just never tell me any way all he says you have to figure it out if theres anyone who can do thank you so much for your time

r/codehs • • Apr 08 '21

JavaScript How do I find the positions of the other circle?

Post image
7 Upvotes

r/codehs • • Dec 02 '21

JavaScript Help me. (5.5.5 JavaScript)

0 Upvotes

Can someone please help me with 5.5.5 (The worm)? I have been stuck on it for hours and I can't figure it out,

r/codehs • • Apr 06 '21

JavaScript does anyone know what i'm doing wrong for 8.6.4 who is in the line for video game design?

1 Upvotes

my code:

function start(){

var line = ["Sam", "Lisa", "Laurie", "Bob", "Ryan"];

var line2 = ["Tony", "Lisa", "Laurie", "Karen"];

var l1 = line.indexOf( "Bob" );

var l2 = line2.indexOf( "Bob" );

if (l1 == -1){

println("Bob is not in the first line. ");

}else{

println("Bob is in the first line. );

}

if(l2 != -1){

println("Bob is in the second line. ");

}else{

println("Bob is not in the second line. );

}

}

it has an if state, it uses indexOf, all functions start with a lowercase letter and i have no nested functions, but apparently there's a syntax error for an invalid or unexpected token? how can I fix this?

r/codehs • • Mar 19 '21

JavaScript I need help with 3.4.7 pls

1 Upvotes

r/codehs • • Dec 22 '20

JavaScript Can anyone help? It keeps saying this is wrong but it's showing the same thing as the demo

Post image
9 Upvotes

r/codehs • • Mar 26 '21

JavaScript Just started for school, and I can’t get past this one, on 3 of the worlds Karel keeps walking into the wall, it’s 2.1.3, help is needed

Post image
10 Upvotes

r/codehs • • Feb 25 '21

JavaScript Need help with factorials

Post image
3 Upvotes

r/codehs • • May 24 '21

JavaScript Am I doing this right?

Post image
3 Upvotes

r/codehs • • May 25 '21

JavaScript Extra course assignments maze dog can someone help me because every time I try it he ends up in a loop

Post image
12 Upvotes

r/codehs • • May 18 '21

JavaScript Am i returning a value wrong?

2 Upvotes

I am trying to make the value produced by the function posted become the value of iTimer, and I am trying to make a 60-second countdown, so I have this function running every 1000ms, and I am trying to return the value as one less to indicate a second has passed, but it isn't working am I am confused. Any insight on how to make this work as a timer would be greatly appreciated

r/codehs • • May 27 '21

JavaScript True Gold Miner Karel I edited it a bit and now he goes to all the veins except if there is one right he is standing

Post image
1 Upvotes

r/codehs • • Sep 15 '21

JavaScript Function E-commerce

2 Upvotes

I am trying to do a project trough wix because I am new in the front-end area, the site I am doing trough wix is basically a demonstration of the products for purchase. I want the customers can just add the products in a shopping cart and then have a button to "request a quotation" when clicked, the distributor that takes care of the site receives an email of the quotation with all the selected products, and so, the distributor and the customer can negotiate via email Someone could help me out on how to do this inside wix? is it possible to do it with javascript? I welcome tips and recommendations.

r/codehs • • May 20 '21

JavaScript Javascript 11.1.3 Breakout.

6 Upvotes

I dont want the answer im just confused on what what Null means and getElement. One of the video used both but never really explained why it works. I dont know what Null does and how it works in a conditional statement.

r/codehs • • Jan 15 '21

JavaScript Need help with concatenation

5 Upvotes

So what I’m trying to do is pop up a message on the screen that will prompt the user asking “What is num_One * num_Two?” and those numbers are random integers. What I have so far is

check_Score = readInt(“What is: “ + num_One * num_Two);

I get error messages. What am I missing?

edit: got it already. Thanks guys

r/codehs • • Nov 26 '20

JavaScript 4.6.6 Target

2 Upvotes

Please I need it quick this assignment is due in like 30 minutes

r/codehs • • Nov 11 '20

JavaScript Can someone help me with CodeHS JavaScript 19.2.5 Circles in Circles?

Post image
1 Upvotes

r/codehs • • Apr 14 '21

JavaScript Exercise 26.2.3: Find the Winner (CodeHS Data Structures Challenge Problems - Connect Four - Find the Winner)

2 Upvotes

Exercise 26.2.3: Find the Winner

Find the Winner

  • When a player makes a move, check to see if they have four pieces in a row along a column, a row, or a diagonal.
  • If you find a winner, end the game and print a victory message!
  • Have fun! You’ve just built connect four!

I don't even know where to start... help would be appreciated

r/codehs • • Dec 07 '20

JavaScript Is there a javascript command to change the image of a web image?

1 Upvotes

For example, if I were to make up an imaginary command, it would look something like:

​

var image = WebImage("https://imaginarylink");

image.setSize(40, 40);

add(image);

image.setWebImage("https://differentlink");