javascript function looping array
Why can't I get the output I want, I tried various ways but it doesn't work, where is it wrong? Give me a clue so I can learn. let laptop = ["asus", "lenovo", "acer", "hp", "axioo"]; let gpu = [4070,…
Why can't I get the output I want, I tried various ways but it doesn't work, where is it wrong? Give me a clue so I can learn. let laptop = ["asus", "lenovo", "acer", "hp", "axioo"]; let gpu = [4070,…
My Question/ Expectation is to find a possible point or statment that could cause such problems. If you have experienced something similar in JS, where it does go through the whole Function but only calculations one part, and have a…
I am working on an app in Android Studio. I made a few buttons in my HTML and had put the 'onclick=""' value as my functions for each button as needed. When the page loads, the JavaScript loads the function…
please when create an elevated button and then give it an empty funtion it indicates an error which doesn't allow my code to run. Even if i give it a simple function it still doesnt work. can someone please help…
i'm currently working on an etch-a-sketch on the odin project. Here's the code I've come up with. const container = document.querySelector(".container"); const input = document.querySelector("input"); const submitBtn = document.querySelector("button"); function createGrid() { let value=input.value; for (let i = 0; i…
I need help to correct the PHP function. For explanation: I have a price 1.45 and I need to add 10% to this price, but with no roundings. It should show up in woocommerce: 1,595 Hope I explain right :-)…
Below is a trivialized version of a solution I came across while trying to implement a version of the Jquery CSS function. function CSS(prop, value) { ... if (value === undefined) { // No matching elements. if (element == null)…
Per the Odin Project's instructions, I need to make my basic calculator operate via math functions rather than using eval(). https://www.theodinproject.com/lessons/foundations-calculator I've only added the addition part to my mathWorks function. However, I'm not sure how to tie my mathWorks…
As demonstrated in the below examples, I used the function keyword to declare a function that will generate a random integer number within a range, and I also used a const keyword to declare another function that will convert a…
I have been wrapping my head around pseudoclassical inheritance in Javascript , and continuing on this topic I wanted to set an Static property/method , for a defined Constructor function. I want to avoid the class syntax for it. function…