TASK #1 - Dot Product You are given 2 arrays of same size, @a and @b. Write a script to implement Dot Product. Example: @a = (1, 2, 3); @b = (4, 5, 6); $dot_product = (1 * 4) + (2 * 5) + (3 * 6) => 4 + 10 + 18 => 32 MY NOTES: Very easy. TASK #2 - Palindromic Tree You are given a string $s. Write a script to create a Palindromic Tree for the given string. I found this blog exaplaining Palindromic Tree in detail: https://medium.com/@alessiopiergiacomi/eertree-or-palindromic-tree-82453e75025b Example 1: Input: $s = 'redivider' Output: r redivider e edivide d divid i ivi v Example 2: Input: $s = 'deific' Output: d e i ifi f c Example 3: Input: $s = 'rotors' Output: r rotor o oto t s Example 4: Input: $s = 'challenge' Output: c h a l ll e n g Example 5: Input: $s = 'champion' Output: c h a m p i o n Example 6: Input: $s = 'christmas' Output: c h r i s t m a MY NOTES: hmm.. I read the blog, but what on earth is it talking about, it's not very clear? the underlying paper https://arxiv.org/pdf/1506.04862.pdf is a lot clearer, but still way too detailed for 10pm on a Sunday. Looking at the examples given above, the output seems to be a list of palindromic substrings not previously encountered, in the natural order found by sequencing through every starting position in the word and trying increasingly long substrings for "Palindromic"-ness. So, could we solve the "generate the output from the input" problem, entirely ignoring the whole "build a weird tree" part of it? Presumably a lot less efficient than their clever eertree/Palindrome tree thingy, but who cares.