JSFiddle

missyalyssi's public fiddles

  • Coin changing

    Using Recursion and dynamic programing Given a value N, if we want to make change for N cents, and we have infinite supply of each of S = { S1, S2, .. , Sm} valued coins, how many ways can we make the change? The order of coins doesn’t matter. For example, for N = 4 and S = {1,2,3}, there are four solutions: {1,1,1,1},{1,1,2},{2,2},{1,3}. So output should be 4.

  • Edit distance

    Using Recursion and dynamic programing Given two text strings A of length n and B of length m, you want to transform A into B with a minimum number of operations of the following types: delete a character from A, insert a character into A, or change some character in A into a new character. The minimal number of such operations required to transform A into B is called the edit distance between A and B

  • Edit distance

    Using Recursion and dynamic programing Given two text strings A of length n and B of length m, you want to transform A into B with a minimum number of operations of the following types: delete a character from A, insert a character into A, or change some character in A into a new character. The minimal number of such operations required to transform A into B is called the edit distance between A and B

  • Longest common subsequence

    Using Recursion and dynamic programing Given two strings ‘X’ and ‘Y’, find the length of the longest common subsequence.

  • Longest common subsequence

    Using Recursion and dynamic programing Given two strings ‘X’ and ‘Y’, find the length of the longest common subsequence.

  • Longest common subsequence

    Using Recursion and dynamic programing Given two strings ‘X’ and ‘Y’, find the length of the longest common subsequence.

  • Knapsack problem

    Using Recursion and dynamic programing Given weights and values of n items, put these items in a knapsack of capacity c to get the maximum total value in the knapsack. In other words, given two integer arrays val[0..n-1] and wt[0..n-1] which represent values and weights associated with n items respectively. Also given an integer W which represents knapsack capacity, find out the maximum value subset of val[] such that sum of the weights of this subset is smaller than or equal to W. You cannot break an item, either pick the complete item, or don’t pick it (0-1 property).

  • Return unique

    Given a multidimensional input array, the function returns an output array containing the unique elements. To be unique the elements must appear in the same order on the top level but this is not required for the inner arrays. For example, by our definition: [[8],[1,2,3],[9]] is a duplicate of [[8], [3,1,2], [9]] but it is not a duplicate of [[9], [3,1,2], [8]]

  • Fair workload

    No-Library (pure JS), HTML, CSS, JavaScript

  • Fair workload

    No-Library (pure JS), HTML, CSS, JavaScript

  • Cryptarithmetic

    Cryptarithmetic is the science and art of creating and solving cryptarithms. A Cryptarithmetic is a genre of mathematical puzzle in which the digits are replaced by letters of the alphabet or other symbols BASE +BALL ------------ GAMES Answer is: A=4, B=7, S=8, E=3, L=5, G=1,and M=9 If the same letter occurs more than once, it must be assigned the same digit each time. This means the words being added must be the same

  • IELTS Spelling

    No-Library (pure JS), HTML, CSS, JavaScript