Ahmed's public fiddles
-
get a random item from an array.
No-Library (pure JS), HTML, CSS, JavaScript
-
program to flatten a nested (any depth) array
program to flatten a nested (any depth) array
-
function to sort the following array of objects by title value.
var library = [ { author: 'Bill Gates', title: 'The Road Ahead', libraryID: 1254}, { author: 'Steve Jobs', title: 'Walter Isaacson', libraryID: 4264}, { author: 'Suzanne Collins', title: 'Mockingjay: The Final Book of The Hunger Games', libraryID: 3245} ];
-
function to remove. 'null', '0', '""', 'false', 'undefined' and 'NaN' values from an array.
function to remove. 'null', '0', '""', 'false', 'undefined' and 'NaN' values from an array.
-
Write a JavaScript program to find duplicate values in a JavaScript array.
Write a JavaScript program to find duplicate values in a JavaScript array.
-
Compute the sum of each individual index value of two or more arrays
Compute the sum of each individual index value of two or more arrays
-
Find the leap years in a given range of years
Find the leap years in a given range of years
-
Write a JavaScript program to shuffle an array.
Write a JavaScript program to shuffle an array.
-
exponent with recursion
Eloquent JS
-
chess board
chess board
-
using \n
eloquent JS practice
-
Write a JavaScript program to add items in an blank array and display the items.
Write a JavaScript program to add items in an blank array and display the items.
-
program to remove duplicate items from an array
program to remove duplicate items from an array
-
check whether an `input` is an array or not
check whether an `input` is an array or not
-
write a JavaScript program to display the colors in the following way :
//"1st choice is Blue ." //"2nd choice is Green." //"3rd choice is Red."
-
Swap the case of each character of a string,
Swap the case of each character of a string,
-
program which accept a number as input and insert dashes (-) between each two even numbers.
program which accept a number as input and insert dashes (-) between each two even numbers.
-
Write a program which prints the elements of the following array.
Write a program which prints the elements of the following array.
-
Sort the items of an array
Sort the items of an array
-
Write a JavaScript function to get the last element of an array. Passing a parameter 'n' will return the last 'n' elements of the array.
Write a JavaScript function to get the last element of an array. Passing a parameter 'n' will return the last 'n' elements of the array.