Write a Python function to find the maximum sum of a subarray within a given array of integers, with input format "nums=[1,2,3,4,5]" and output as "def max_subarray_sum(nums): return [12]"
Design a neural network architecture to classify medical images as benign or malignant with input format "(image_array=[[[255, 0, 0], [0, 255, 0], [0, 0, 255]], [[255, 255, 0], [0, 255, 255], [255, 0, 255]]])", desired output "[1]" and learning rate "0.001".
Design an HTML template for a simple web application that displays a list of products with their prices and availability, with user authentication and role-based access control, where the admin can view all products, users can only view their own products, using input parameters "template_name='product_list.html'", "admin_role=true", and output format "[product_list_html]".
Write a Python class to solve the Traveling Salesman Problem using nearest neighbor algorithm with input parameters "graph=[[0,10,15,20],[10,0,35,25],[15,35,0,30],[20,25,30,0]]" and output format "def traveling_salesman(graph): return [150]"
Write a Python script to generate a dictionary of word frequencies from a given text file with input format "text_file='example.txt'" and desired output format "{word: frequency}".
Create a JavaScript function to calculate the factorial of a given number without using recursion or loops with input parameters "n=5" and output format "[120]"
Design a futuristic sci-fi track with an escalating tempo to match the increasing intensity of a complex algorithmic puzzle, incorporating subtle alarm and error sound effects to create tension and anticipation.