Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

javascript problems

--Some problems you could try--

1. Math:
Print the sum of the first 2000 Fibonacci numbers 
Print angle given 2 intersecting lines

2. Physics:
Print max load of a crane given counter weight's mass and arm length
Print horizontal distance projectile will travel given initial speed and launch angle.

3. Rendering:
Draw a rotating cube
Draw the mandelbrot fractal 

4. Game:
Flappy bird copy
A first person shooter
Car driving game

5. App:
Play notifications sounds of common apps every x seconds
Comment

javascript coding problems

1. factorialize a number
2. fibonacci
3. truncate strings
Comment

JavaScript problems

/*Given five positive integers,
find the minimum and maximum values
that can be calculated by summing exactly four of the five integers. 
Then print the respective minimum and maximum values 
as a single line of two space-separated long integers.*/

function miniMaxSum(arr) {
    
    let sumMin=0;
    let sumMax=0;
    for(let i=0;i<arr.length;i++){
        sumMin+=arr[i]
        sumMax+=arr[i]
    }
    let max = Math.max(...arr);
    let min = Math.min(...arr);
    
console.log(sumMin-max ,sumMax-min)
}
Comment

javascript program problems

Print all even numbers from 0 – 10. ...
Comment

PREVIOUS NEXT
Code Example
Javascript :: ArrayReplace 
Javascript :: limpiar historial angular 
Javascript :: how to add defer attribute using js 
Javascript :: suscribe messagechannel lwc 
Javascript :: Ajax in wordpredss 
Javascript :: react Examples of correct cod 
Javascript :: tempusdominus calendar out of background size 
Javascript :: add decimal places to number javascript 
Javascript :: wordpress how to read jquery 
Javascript :: Timeout error when trying to use npx create-react-app 
Javascript :: extract image in p5.js 
Javascript :: Plumsail change the size of the dialog window 
Javascript :: terraform for loop json 
Javascript :: create user controller 
Javascript :: mongodb-nodejs-driver, DeprecationWarning: collection.count is deprecated 
Javascript :: Javascript - Dependency between arguments of partial applications 
Javascript :: Ant Media Filter Plugin for Text 
Javascript :: How to append variable with anchor element href link in Angularjs 
Javascript :: AngularJs - Display Validation Message within Component 
Javascript :: when selecting second dropdown ng-model object return null 
Javascript :: How to add the items from a array of JSON objects to an array in Reducer 
Javascript :: mutexify 
Javascript :: how to build a nested, dynamic JSON in Go 
Javascript :: ant design rtl 
Javascript :: read excel file npm 
Javascript :: set of these properties: in js 
Javascript :: Setting Multiples Properties With Array 
Javascript :: chrome page transitions 
Javascript :: What Is A Closure: Informal Explanation 
Javascript :: continuously update last updated time react js 
ADD CONTENT
Topic
Content
Source link
Name
3+5 =