- 2
The speed of sound in air is 343 meters per second. Create a program that takes the seconds as input, calculates and outputs to
How to do it
28 Antworten
+ 4
It is just a multiplication.
https://code.sololearn.com/WUD5TTIHNAyh/?ref=app
+ 4
I wouldnt sweat the xp honestly nobody seems to know the answer and maybe we have to finish the course to finish it which is pointless in learning along the lesson but its whatever.
+ 4
speed = 343
time = 600
console.log(speed*time)
+ 3
Your question is incomplete, make sure to put the actual question in the description and not in the heading.
+ 3
im so lost on this, seriously about to cancel and give up, they did not teach enough prior to giving us this problem
+ 1
I do not know what's the problem with you. In sololearn you cannot write JS code separately, it comes inside web as a whole package. The above code works just fine.
Just enter the number of seconds.
+ 1
I did not know you are asking for a code coach problem. I'm not sure but for the given statement, this should work.
var seconds = parseInt(prompt());
var soundSpeed = 343;
console.log(seconds*soundSpeed)
+ 1
This one line should work.
console.log(343*seconds);
+ 1
Im stuck on the same question and cant seem to change the output for each test case. It says not to overwelm you we've hidden the code that executes the output as a comment. Ill post my code so you know my efforts.
function main() {
var x = 343;
var y = 1;
var z = 3;
var w = 4;
var a = eval("x * z");
var b = eval("x * y");
var c = eval("x * w");
console.log(a);
}
function parseInt(){
var x = 343;
var y = 1;
var z = 3;
var w = 4;
var a = eval("x * z");
var b = eval("x * y");
var c = eval("x * w");
console.log(b);}
function main() {
var x = 343;
var y = 1;
var z = 3;
var w = 4;
var a = eval("x * z");
var b = eval("x * y");
var c = eval("x * w");
console.log(c);}
+ 1
function speed(){
let x = 343;
let z = 600;
console.log( x * z)
}
speed()
0
I meant to say the first question in JavaScript after completing basics named as MATH OPERATOR 1
Help me to Get of this
0
The speed of sound in air is 343 meters per second.
Create a program that takes the seconds as input, calculates and outputs to the console the distance the sound covers in a given number of seconds.
Sample Input
3
Sample Output
1029
The total distance that sound covers in 3 seconds is 3*343 = 1029.
0
Have you got the answer
0
JavaScript man
0
I have tried it.
the link above you mentioned not working
It has to be solved in JavaScript only
And the above one had html,css, JavaScript
0
I have tried it it's not working
0
In the result section it's showing
Test case#1 is right
And the below ones are wrong
Test case#2
Test case#3
Test case#4
0
The above one also not working
0
Have you done coach problem
0
Tried even before i had dropped question into this q&A